Warning.vue 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <template>
  2. <div class="Warning">
  3. <div class="icon">
  4. <svg xmlns="http://www.w3.org/2000/svg"
  5. width="20"
  6. height="20"
  7. viewBox="0 0 20 20">
  8. <g id="Info_Square"
  9. data-name="Info Square"
  10. transform="translate(0)">
  11. <path id="Combined_Shape"
  12. data-name="Combined Shape"
  13. d="M5.664,20C2.276,20,0,17.623,0,14.084V5.916C0,2.377,2.276,0,5.664,0h8.671C17.723,0,20,2.377,20,5.916v8.168C20,17.623,17.722,20,14.332,20ZM1.5,5.916v8.168c0,2.683,1.634,4.416,4.163,4.416h8.668c2.533,0,4.169-1.733,4.169-4.416V5.916c0-2.682-1.635-4.415-4.166-4.415H5.664C3.135,1.5,1.5,3.234,1.5,5.916ZM9.244,14V10a.75.75,0,0,1,1.5,0v4a.75.75,0,0,1-1.5,0Zm-.25-7.8a1,1,0,0,1,1-1H10a1,1,0,1,1-1.005,1Z"
  14. transform="translate(0)"
  15. fill="#ff3d3d" />
  16. </g>
  17. </svg>
  18. </div>
  19. <div class="message">
  20. {{label}}
  21. </div>
  22. </div>
  23. </template>
  24. <script>
  25. export default {
  26. name: 'Warning',
  27. props: {
  28. label: {
  29. default: '',
  30. type: String
  31. }
  32. }
  33. }
  34. </script>
  35. <style lang="scss" scoped>
  36. .Warning {
  37. display: flex;
  38. flex-flow: row;
  39. justify-content: flex-start;
  40. align-items: center;
  41. position: relative;
  42. background-color: #FFEAEA;
  43. padding: 12px 20px;
  44. border-radius: 8px;
  45. .icon {
  46. margin-right: 6px;
  47. display: flex;
  48. align-items: center;
  49. justify-content: center;
  50. }
  51. .message {
  52. color: #FF3D3D;
  53. }
  54. }
  55. </style>