@usssa/component-library 1.0.0-alpha.10 → 1.0.0-alpha.100

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/README.md +5 -2
  2. package/package.json +19 -4
  3. package/src/assets/files.png +0 -0
  4. package/src/assets/logo.svg +19 -0
  5. package/src/assets/no-result.png +0 -0
  6. package/src/assets/quasar-logo-vertical.svg +15 -0
  7. package/src/components/core/UAvatar.vue +39 -6
  8. package/src/components/core/UAvatarGroup.vue +15 -14
  9. package/src/components/core/UBannerStd.vue +51 -22
  10. package/src/components/core/UBreadCrumbs.vue +67 -0
  11. package/src/components/core/UBtnIcon.vue +24 -14
  12. package/src/components/core/UBtnStd.vue +35 -31
  13. package/src/components/core/UBtnToggle.vue +68 -0
  14. package/src/components/core/UCheckboxStd.vue +25 -8
  15. package/src/components/core/UChip.vue +30 -4
  16. package/src/components/core/UDialogStd.vue +244 -0
  17. package/src/components/core/UDrawer.vue +235 -0
  18. package/src/components/core/UInnerLoader.vue +58 -0
  19. package/src/components/core/UInputAddressLookup.vue +470 -0
  20. package/src/components/core/UInputPhoneStd.vue +299 -0
  21. package/src/components/core/UInputTextStd.vue +114 -85
  22. package/src/components/core/UInputTypeaheadAdvanceSearch.vue +59 -0
  23. package/src/components/core/UMenuButtonStd.vue +274 -0
  24. package/src/components/core/UMenuDropdown.vue +72 -0
  25. package/src/components/core/UMenuDropdownAdvancedSearch.vue +301 -0
  26. package/src/components/core/UMenuItem.vue +134 -0
  27. package/src/components/core/UMenuSearch.vue +752 -0
  28. package/src/components/core/UMultiSelectStd.vue +63 -57
  29. package/src/components/core/UPagination.vue +104 -0
  30. package/src/components/core/URadioBtn.vue +116 -0
  31. package/src/components/core/URadioStd.vue +7 -3
  32. package/src/components/core/USelectStd.vue +74 -59
  33. package/src/components/core/UTabBtnStd.vue +82 -59
  34. package/src/components/core/UTable/UTable.vue +93 -0
  35. package/src/components/core/UTable/UTd.vue +63 -0
  36. package/src/components/core/UTable/UTh.vue +48 -0
  37. package/src/components/core/UTable/UTr.vue +20 -0
  38. package/src/components/core/UTableStd.vue +1003 -0
  39. package/src/components/core/UTabsStd.vue +17 -5
  40. package/src/components/core/UToggleStd.vue +30 -20
  41. package/src/components/core/UToolbar.vue +94 -0
  42. package/src/components/core/UTooltip.vue +25 -4
  43. package/src/components/core/UUploader.vue +497 -0
  44. package/src/components/index.js +57 -6
  45. package/src/composables/useNotify.js +79 -0
  46. package/src/composables/useOverlayLoader.js +23 -0
  47. package/src/css/app.sass +159 -0
  48. package/src/css/colors.sass +101 -0
  49. package/src/css/media.sass +1 -0
  50. package/src/css/quasar.variables.sass +121 -0
  51. package/src/css/typography.sass +0 -0
  52. package/src/css/vars/colors.variables.sass +126 -0
  53. package/src/utils/data.ts +146 -0
package/README.md CHANGED
@@ -1,13 +1,16 @@
1
1
  # Component Library
2
2
 
3
- This library provides custom UI components for USSSA applications.
3
+ **This library provides custom UI components for USSSA applications.**
4
4
 
5
5
  ## Installation
6
6
 
7
7
  1. Install the packge using command 'yarn'
8
8
  2. Go to specific page where you want to use a component from that library.
9
- a. Import the library in your Quasar project: `import { UBtnStd } from 'component-library'`
9
+ a. Import the component in your project: `import { UBtnStd } from '@usssa/component-library'`
10
10
  b. Use the BtnStd component in your Nuxt app: `<UBtnStd label="Test" size="lg" />`
11
+ 3. We need to import below file to support component library styling in our project
12
+ a. @import '@usssa/component-library/src/css/app.sass'
13
+ b. @import '@usssa/component-library/src/css/quasar.variables.sass'
11
14
 
12
15
  ## Development
13
16
 
package/package.json CHANGED
@@ -1,13 +1,18 @@
1
1
  {
2
2
  "name": "@usssa/component-library",
3
- "version": "1.0.0-alpha.10",
3
+ "version": "1.0.0-alpha.100",
4
4
  "description": "A Quasar component library project",
5
5
  "productName": "Quasar component library App",
6
6
  "author": "Troy Moreland <troy.moreland@usssa.com>",
7
7
  "main": "src/components/index.js",
8
8
  "files": [
9
+ "src/assets",
10
+ "src/composables",
9
11
  "src/components",
10
- "README.md"
12
+ "src/css",
13
+ "src/utils",
14
+ "README.md",
15
+ "package.json"
11
16
  ],
12
17
  "publishConfig": {
13
18
  "access": "public"
@@ -22,8 +27,15 @@
22
27
  "build": "quasar build",
23
28
  "start": "node --experimental-detect-module index.js"
24
29
  },
30
+ "repository": {
31
+ "type": "git",
32
+ "url": "git+https://github.com/usssa-org/component-library.git"
33
+ },
25
34
  "dependencies": {
35
+ "@fawmi/vue-google-maps": "^0.9.79",
26
36
  "@quasar/extras": "^1.16.4",
37
+ "algoliasearch": "4",
38
+ "flag-icons": "^7.2.3",
27
39
  "quasar": "^2.16.0",
28
40
  "vue": "^3.4.18",
29
41
  "vue-router": "^4.0.12"
@@ -31,13 +43,15 @@
31
43
  "devDependencies": {
32
44
  "@quasar/app-vite": "^1.9.0",
33
45
  "autoprefixer": "^10.4.2",
46
+ "dotenv": "^16.4.5",
34
47
  "eslint": "^8.57.0",
35
48
  "eslint-config-prettier": "^8.1.0",
36
49
  "eslint-plugin-vue": "^9.0.0",
37
50
  "npm-run-all": "^4.1.5",
38
51
  "postcss": "^8.4.14",
39
52
  "prettier": "^2.5.1",
40
- "semantic-release": "^24.0.0",
53
+ "semantic-release": "^24.1.0",
54
+ "vite-plugin-alias": "^0.1.1",
41
55
  "vite-plugin-checker": "^0.6.4"
42
56
  },
43
57
  "engines": {
@@ -49,5 +63,6 @@
49
63
  "bugs": {
50
64
  "url": "https://github.com/usssa-org/component-library/issues"
51
65
  },
52
- "license": "ISC"
66
+ "license": "ISC",
67
+ "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
53
68
  }
Binary file
@@ -0,0 +1,19 @@
1
+ <svg width="95" height="24" viewBox="0 0 95 24" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g id="Logo">
3
+ <g id="Lettering">
4
+ <path d="M3.80408 2.66675H8.95923L4.80595 13.2946L11.6168 13.2333L15.8059 2.66675H20.8L16.7704 12.978C15.8482 15.3379 13.5896 16.889 11.0754 16.889H3.24023L3.23972 16.8853C0.95221 16.7796 -0.597379 14.4417 0.221722 12.2504L3.80408 2.66675Z" fill="#234BA9"/>
5
+ <path d="M25.3431 2.66675C24.1871 2.66675 23.1592 3.40891 22.7861 4.5129L22.2017 6.24262L21.3962 8.1931L20.9479 9.20419C20.5153 10.1799 21.2229 11.2814 22.2822 11.2814H30.0955L29.3215 13.3117H19.4306L17.9807 16.8876H30.4658C31.6432 16.8876 32.7118 16.1933 33.199 15.1119L34.01 13.3117H33.9934L34.7674 11.2814H34.7746L35.0296 10.6669C35.5176 9.49105 34.6615 8.1931 33.398 8.1931H26.3902L27.1957 6.24262H36.3783L37.8282 2.66675H25.3431Z" fill="#234BA9"/>
6
+ <path d="M65.9075 2.66675C64.7515 2.66675 63.7235 3.40891 63.3505 4.5129L62.7661 6.24262L61.9606 8.1931L61.5123 9.20419C61.0797 10.1799 61.7873 11.2814 62.8466 11.2814H70.6599L69.8859 13.3117H59.995L58.5451 16.8876H71.0302C72.2076 16.8876 73.2762 16.1933 73.7634 15.1119L74.5744 13.3117H74.5578L75.3318 11.2814H75.339L75.594 10.6669C76.0819 9.49105 75.2259 8.1931 73.9624 8.1931H66.9546L67.7601 6.24262H76.9427L78.3926 2.66675H65.9075Z" fill="#234BA9"/>
7
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M92.0723 2.66675H80.9702L79.6009 6.24262H89.5386L88.7205 8.27437H81.103C79.3981 8.27437 77.8944 9.40113 77.4017 11.0479L76.8451 12.908C76.2519 14.8906 77.7229 16.8889 79.7755 16.8888L90.3945 16.8883L93.6818 8.51818H93.697L94.5025 6.24262C95.162 4.52034 93.9023 2.66675 92.0723 2.66675ZM81.373 13.3131L82.259 11.2001H87.6558L86.7698 13.3131H81.373Z" fill="#234BA9"/>
8
+ </g>
9
+ <path id="top" d="M47.7783 0.00113767H62.8782C61.1471 3.8405 58.0313 4.88033 55.3948 4.88033H49.6691V1.41424L47.2456 4.88033H43.464L45.8076 6.95998L43.464 10.3994L47.3255 8.34642L49.6957 10.4794L49.6691 6.95998H54.5426C58.271 6.93332 58.8036 10.4794 58.1378 11.8125H42.7184C41.3069 11.8125 37.1258 10.7724 39.0166 5.76018C40.7743 1.78735 44.982 -0.0524702 47.7783 0.00113767Z" fill="#234BA9"/>
10
+ <g id="bottom">
11
+ <path d="M32.3588 20.1976C32.705 18.5712 34.7556 15.5317 38.484 15.2917H46.1804C46.3668 15.2917 46.8835 15.2704 47.2456 14.5452L47.7516 13.1987H57.6318C57.2324 14.2741 55.7943 16.5448 52.6518 16.7315H46.5532C46.5 16.7315 45.6899 16.8463 45.3282 17.6913C44.9287 18.6245 44.2097 18.7845 43.8368 18.8111H35.9007C35.2616 18.8378 33.7702 19.0511 32.3588 20.1976Z" fill="#CB2A3D"/>
12
+ <path d="M56.1937 16.7181C55.7943 18.3445 53.8875 21.4054 50.0952 21.5973H44.1032C43.5439 21.6507 42.9484 21.7679 42.6118 22.6105C42.2603 23.4904 41.4933 23.7037 40.9873 23.7037H30.8674C31.258 22.6372 32.7902 20.4455 35.7942 20.2109H43.5173C43.7658 20.202 44.2363 20.1842 44.6092 19.3044C44.982 18.4245 45.2217 18.1312 46.0639 18.1046H52.6252C53.1844 18.1135 54.8089 17.838 56.1937 16.7181Z" fill="#CB2A3D"/>
13
+ </g>
14
+ <g id="shadow">
15
+ <path d="M49.7491 13.1987L48.3643 16.7315H46.7132C46.367 16.7493 45.6394 16.9261 45.2985 17.758L46.2871 15.2864C46.4735 15.2784 46.8996 15.1611 47.2192 14.5852L47.7518 13.1987H49.7491Z" fill="#951F23"/>
16
+ <path d="M42.6119 22.6114L42.6274 22.5736C42.959 21.7945 43.8175 21.5982 44.2631 21.5982H45.6745L47.0594 18.1055H46.0474C45.1419 18.0788 44.8377 18.6727 44.5747 19.3844C44.4761 19.651 44.1299 20.1538 43.5973 20.2072L42.6274 22.5736C42.6221 22.586 42.617 22.5986 42.6119 22.6114Z" fill="#951F23"/>
17
+ </g>
18
+ </g>
19
+ </svg>
Binary file
@@ -0,0 +1,15 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 356 360">
2
+ <path
3
+ d="M43.4 303.4c0 3.8-2.3 6.3-7.1 6.3h-15v-22h14.4c4.3 0 6.2 2.2 6.2 5.2 0 2.6-1.5 4.4-3.4 5 2.8.4 4.9 2.5 4.9 5.5zm-8-13H24.1v6.9H35c2.1 0 4-1.3 4-3.8 0-2.2-1.3-3.1-3.7-3.1zm5.1 12.6c0-2.3-1.8-3.7-4-3.7H24.2v7.7h11.7c3.4 0 4.6-1.8 4.6-4zm36.3 4v2.7H56v-22h20.6v2.7H58.9v6.8h14.6v2.3H58.9v7.5h17.9zm23-5.8v8.5H97v-8.5l-11-13.4h3.4l8.9 11 8.8-11h3.4l-10.8 13.4zm19.1-1.8V298c0-7.9 5.2-10.7 12.7-10.7 7.5 0 13 2.8 13 10.7v1.4c0 7.9-5.5 10.8-13 10.8s-12.7-3-12.7-10.8zm22.7 0V298c0-5.7-3.9-8-10-8-6 0-9.8 2.3-9.8 8v1.4c0 5.8 3.8 8.1 9.8 8.1 6 0 10-2.3 10-8.1zm37.2-11.6v21.9h-2.9l-15.8-17.9v17.9h-2.8v-22h3l15.6 18v-18h2.9zm37.9 10.2v1.3c0 7.8-5.2 10.4-12.4 10.4H193v-22h11.2c7.2 0 12.4 2.8 12.4 10.3zm-3 0c0-5.3-3.3-7.6-9.4-7.6h-8.4V307h8.4c6 0 9.5-2 9.5-7.7V298zm50.8-7.6h-9.7v19.3h-3v-19.3h-9.7v-2.6h22.4v2.6zm34.4-2.6v21.9h-3v-10.1h-16.8v10h-2.8v-21.8h2.8v9.2H296v-9.2h2.9zm34.9 19.2v2.7h-20.7v-22h20.6v2.7H316v6.8h14.5v2.3H316v7.5h17.8zM24 340.2v7.3h13.9v2.4h-14v9.6H21v-22h20v2.7H24zm41.5 11.4h-9.8v7.9H53v-22h13.3c5.1 0 8 1.9 8 6.8 0 3.7-2 6.3-5.6 7l6 8.2h-3.3l-5.8-8zm-9.8-2.6H66c3.1 0 5.3-1.5 5.3-4.7 0-3.3-2.2-4.1-5.3-4.1H55.7v8.8zm47.9 6.2H89l-2 4.3h-3.2l10.7-22.2H98l10.7 22.2h-3.2l-2-4.3zm-1-2.3l-6.3-13-6 13h12.2zm46.3-15.3v21.9H146v-17.2L135.7 358h-2.1l-10.2-15.6v17h-2.8v-21.8h3l11 16.9 11.3-17h3zm35 19.3v2.6h-20.7v-22h20.6v2.7H166v6.8h14.5v2.3H166v7.6h17.8zm47-19.3l-8.3 22h-3l-7.1-18.6-7 18.6h-3l-8.2-22h3.3L204 356l6.8-18.5h3.4L221 356l6.6-18.5h3.3zm10 11.6v-1.4c0-7.8 5.2-10.7 12.7-10.7 7.6 0 13 2.9 13 10.7v1.4c0 7.9-5.4 10.8-13 10.8-7.5 0-12.7-3-12.7-10.8zm22.8 0v-1.4c0-5.7-4-8-10-8s-9.9 2.3-9.9 8v1.4c0 5.8 3.8 8.2 9.8 8.2 6.1 0 10-2.4 10-8.2zm28.3 2.4h-9.8v7.9h-2.8v-22h13.2c5.2 0 8 1.9 8 6.8 0 3.7-2 6.3-5.6 7l6 8.2h-3.3l-5.8-8zm-9.8-2.6h10.2c3 0 5.2-1.5 5.2-4.7 0-3.3-2.1-4.1-5.2-4.1h-10.2v8.8zm40.3-1.5l-6.8 5.6v6.4h-2.9v-22h2.9v12.3l15.2-12.2h3.7l-9.9 8.1 10.3 13.8h-3.6l-8.9-12z" />
4
+ <path fill="#050A14"
5
+ d="M188.4 71.7a10.4 10.4 0 01-20.8 0 10.4 10.4 0 1120.8 0zM224.2 45c-2.2-3.9-5-7.5-8.2-10.7l-12 7c-3.7-3.2-8-5.7-12.6-7.3a49.4 49.4 0 00-9.7 13.9 59 59 0 0140.1 14l7.6-4.4a57 57 0 00-5.2-12.5zM178 125.1c4.5 0 9-.6 13.4-1.7v-14a40 40 0 0012.5-7.2 47.7 47.7 0 00-7.1-15.3 59 59 0 01-32.2 27.7v8.7c4.4 1.2 8.9 1.8 13.4 1.8zM131.8 45c-2.3 4-4 8.1-5.2 12.5l12 7a40 40 0 000 14.4c5.7 1.5 11.3 2 16.9 1.5a59 59 0 01-8-41.7l-7.5-4.3c-3.2 3.2-6 6.7-8.2 10.6z" />
6
+ <path fill="#00B4FF"
7
+ d="M224.2 98.4c2.3-3.9 4-8 5.2-12.4l-12-7a40 40 0 000-14.5c-5.7-1.5-11.3-2-16.9-1.5a59 59 0 018 41.7l7.5 4.4c3.2-3.2 6-6.8 8.2-10.7zm-92.4 0c2.2 4 5 7.5 8.2 10.7l12-7a40 40 0 0012.6 7.3c4-4.1 7.3-8.8 9.7-13.8a59 59 0 01-40-14l-7.7 4.4c1.2 4.3 3 8.5 5.2 12.4zm46.2-80c-4.5 0-9 .5-13.4 1.7V34a40 40 0 00-12.5 7.2c1.5 5.7 4 10.8 7.1 15.4a59 59 0 0132.2-27.7V20a53.3 53.3 0 00-13.4-1.8z" />
8
+ <path fill="#00B4FF"
9
+ d="M178 9.2a62.6 62.6 0 11-.1 125.2A62.6 62.6 0 01178 9.2m0-9.2a71.7 71.7 0 100 143.5A71.7 71.7 0 00178 0z" />
10
+ <path fill="#050A14"
11
+ d="M96.6 212v4.3c-9.2-.8-15.4-5.8-15.4-17.8V180h4.6v18.4c0 8.6 4 12.6 10.8 13.5zm16-31.9v18.4c0 8.9-4.3 12.8-10.9 13.5v4.4c9.2-.7 15.5-5.6 15.5-18v-18.3h-4.7zM62.2 199v-2.2c0-12.7-8.8-17.4-21-17.4-12.1 0-20.7 4.7-20.7 17.4v2.2c0 12.8 8.6 17.6 20.7 17.6 1.5 0 3-.1 4.4-.3l11.8 6.2 2-3.3-8.2-4-6.4-3.1a32 32 0 01-3.6.2c-9.8 0-16-3.9-16-13.3v-2.2c0-9.3 6.2-13.1 16-13.1 9.9 0 16.3 3.8 16.3 13.1v2.2c0 5.3-2.1 8.7-5.6 10.8l4.8 2.4c3.4-2.8 5.5-7 5.5-13.2zM168 215.6h5.1L156 179.7h-4.8l17 36zM143 205l7.4-15.7-2.4-5-15.1 31.4h5.1l3.3-7h18.3l-1.8-3.7H143zm133.7 10.7h5.2l-17.3-35.9h-4.8l17 36zm-25-10.7l7.4-15.7-2.4-5-15.1 31.4h5.1l3.3-7h18.3l-1.7-3.7h-14.8zm73.8-2.5c6-1.2 9-5.4 9-11.4 0-8-4.5-10.9-12.9-10.9h-21.4v35.5h4.6v-31.3h16.5c5 0 8.5 1.4 8.5 6.7 0 5.2-3.5 7.7-8.5 7.7h-11.4v4.1h10.7l9.3 12.8h5.5l-9.9-13.2zm-117.4 9.9c-9.7 0-14.7-2.5-18.6-6.3l-2.2 3.8c5.1 5 11 6.7 21 6.7 1.6 0 3.1-.1 4.6-.3l-1.9-4h-3zm18.4-7c0-6.4-4.7-8.6-13.8-9.4l-10.1-1c-6.7-.7-9.3-2.2-9.3-5.6 0-2.5 1.4-4 4.6-5l-1.8-3.8c-4.7 1.4-7.5 4.2-7.5 8.9 0 5.2 3.4 8.7 13 9.6l11.3 1.2c6.4.6 8.9 2 8.9 5.4 0 2.7-2.1 4.7-6 5.8l1.8 3.9c5.3-1.6 8.9-4.7 8.9-10zm-20.3-21.9c7.9 0 13.3 1.8 18.1 5.7l1.8-3.9a30 30 0 00-19.6-5.9c-2 0-4 .1-5.7.3l1.9 4 3.5-.2z" />
12
+ <path fill="#00B4FF"
13
+ d="M.5 251.9c29.6-.5 59.2-.8 88.8-1l88.7-.3 88.7.3 44.4.4 44.4.6-44.4.6-44.4.4-88.7.3-88.7-.3a7981 7981 0 01-88.8-1z" />
14
+ <path fill="none" d="M-565.2 324H-252v15.8h-313.2z" />
15
+ </svg>
@@ -1,11 +1,16 @@
1
1
  <script setup>
2
2
  import { computed } from 'vue'
3
3
  import UBadgeStd from './UBadgeStd.vue'
4
+ import UTooltip from './UTooltip.vue'
5
+
4
6
  const props = defineProps({
5
7
  color: {
6
8
  type: String,
7
9
  default: 'primary',
8
10
  },
11
+ bgColor: {
12
+ type: String,
13
+ },
9
14
  icon: {
10
15
  type: String,
11
16
  },
@@ -35,6 +40,10 @@ const props = defineProps({
35
40
  type: Boolean,
36
41
  default: true,
37
42
  },
43
+ showTooltip: {
44
+ type: Boolean,
45
+ default: false,
46
+ },
38
47
  })
39
48
 
40
49
  const emit = defineEmits(['onClick'])
@@ -59,31 +68,55 @@ const labelSize = computed(() => {
59
68
 
60
69
  return props.size
61
70
  })
71
+
72
+ const initials = computed(() => {
73
+ if (props.name) {
74
+ const name = props.name.replace(/\s+/g, ' ')
75
+ const parts = name.split(' ')
76
+
77
+ if (parts.length === 1) return parts[0].substring(0, 2).toUpperCase()
78
+
79
+ return `${parts[0].substring(0, 1).toUpperCase()}${parts[parts.length - 1]
80
+ .substring(0, 1)
81
+ .toUpperCase()}`
82
+ }
83
+ return props?.name
84
+ })
62
85
  </script>
63
86
 
64
87
  <template>
65
88
  <q-avatar
89
+ v-bind="$attrs"
66
90
  class="u-avatar"
67
91
  :class="`size-${size}`"
68
- @click="handleClick"
92
+ :color="bgColor"
93
+ :icon="icon"
69
94
  :round="round"
70
95
  :rounded="!round"
71
- :icon="icon"
72
- v-bind="$attrs"
96
+ @click="handleClick"
73
97
  >
74
- <img v-if="image" :src="image" :alt="`avatar ${name}`" :aria-label="name" />
98
+ <UTooltip
99
+ v-if="showTooltip"
100
+ anchor="bottom middle"
101
+ :description="name"
102
+ :offset="[4, 4]"
103
+ self="top middle"
104
+ >
105
+ </UTooltip>
106
+ <img v-if="image" :alt="`avatar ${name}`" :aria-label="name" :src="image"/>
75
107
  <span
76
108
  v-if="!image"
77
109
  class="name"
78
110
  :class="`text-${color} text-caption-${labelSize}`"
79
111
  >
80
- {{ name }}
112
+ {{ initials }}
81
113
  </span>
82
114
  <UBadgeStd
83
115
  v-if="showIndicator"
84
- :color="indicatorColor"
85
116
  :class="`indicator`"
117
+ :color="indicatorColor"
86
118
  size="xs"
119
+ tabindex="-1"
87
120
  type="indicator"
88
121
  />
89
122
  <slot name="item" />
@@ -23,10 +23,6 @@ const props = defineProps({
23
23
  type: String,
24
24
  default: 'neutral-4',
25
25
  },
26
- name: {
27
- type: String,
28
- required: true,
29
- },
30
26
  showIndicator: {
31
27
  type: Boolean,
32
28
  default: false,
@@ -39,6 +35,10 @@ const props = defineProps({
39
35
  type: Number,
40
36
  default: 4,
41
37
  },
38
+ showEachTooltip: {
39
+ type: Boolean,
40
+ default: true
41
+ }
42
42
  })
43
43
 
44
44
  const emit = defineEmits(['onClick'])
@@ -59,27 +59,28 @@ const remainingAvatars = computed(() => {
59
59
  <UAvatar
60
60
  v-for="(avatar, index) in displayedAvatars"
61
61
  class="avatarGroup"
62
- :name="avatar.name"
63
- :size="size"
64
- :showIndicator="showIndicator"
65
- :indicatorColor="indicatorColor"
66
- :round="round"
67
62
  :image="avatar.image"
63
+ :indicatorColor="indicatorColor"
68
64
  :key="index"
65
+ :name="avatar.name"
66
+ :round="round"
67
+ :showIndicator="showIndicator"
68
+ :showTooltip="showEachTooltip"
69
+ :size="size"
70
+ tabindex="0"
69
71
  @click="handleClick"
70
72
  />
71
-
72
73
  <q-icon
74
+ v-if="remainingAvatars.length"
73
75
  :class="`avatarGroup additonalUsersAvatar size-${size} fa-duotone fa-solid fa-circle-plus`"
74
- color="primary"
75
76
  aria-label="See more Avatar"
76
- v-if="remainingAvatars.length"
77
+ color="primary"
77
78
  >
78
79
  <UTooltip
79
80
  anchor="bottom middle"
80
81
  description=""
81
- self="top middle"
82
82
  :offset="[4, 4]"
83
+ self="top middle"
83
84
  >
84
85
  <template v-slot:item>
85
86
  <div class="text-body-xs tooltip-text">
@@ -97,7 +98,6 @@ const remainingAvatars = computed(() => {
97
98
  border-radius:50%
98
99
 
99
100
  .additonalUsersAvatar
100
- cursor: pointer
101
101
 
102
102
  &.size-sm
103
103
  font-size: $ba !important
@@ -113,6 +113,7 @@ const remainingAvatars = computed(() => {
113
113
 
114
114
  .avatarGroup
115
115
  margin: -0.125rem
116
+
116
117
  .avatarGroup:not(:nth-child(1)) .q-avatar__content
117
118
  border: 1.5px solid $neutral-1
118
119
  background : lightgray 0px -0.033px / 100% 150.273% no-repeat
@@ -1,12 +1,10 @@
1
1
  <script setup>
2
- import UBtnStd from 'src/components/core/UBtnStd.vue'
3
2
  import { computed } from 'vue'
3
+ import UBtnStd from './UBtnStd.vue'
4
+
5
+ const emit = defineEmits(['primaryAction', 'secondaryAction'])
4
6
 
5
7
  const props = defineProps({
6
- type: {
7
- type: String,
8
- default: 'info',
9
- },
10
8
  icon: {
11
9
  type: String,
12
10
  default: 'fa-kit-duotone fa-circle-info',
@@ -16,22 +14,33 @@ const props = defineProps({
16
14
  default: '',
17
15
  required: true,
18
16
  },
17
+ primaryActionLabel: {
18
+ type: String,
19
+ },
20
+ secondaryActionLabel: {
21
+ type: String,
22
+ },
19
23
  show: {
20
24
  type: Boolean,
21
25
  default: false,
22
26
  required: true,
23
27
  },
24
- primaryActionLabel: {
25
- type: String,
26
- default: 'Action 1',
28
+ showBorder: {
29
+ type: Boolean,
30
+ default: true
27
31
  },
28
- secondaryActionLabel: {
32
+ type: {
29
33
  type: String,
30
- default: 'Action 2',
34
+ default: 'info',
31
35
  },
32
36
  })
33
37
 
34
- const emit = defineEmits(['primaryAction', 'secondaryAction'])
38
+ const bordered = computed(() => {
39
+ if (props.showBorder) {
40
+ return 'bordered'
41
+ }
42
+ return ''
43
+ })
35
44
 
36
45
  const handlePrimaryActionClick = () => {
37
46
  emit('primaryAction')
@@ -45,37 +54,40 @@ const handleSecondaryActionClick = () => {
45
54
  <template>
46
55
  <q-banner
47
56
  v-if="show && message"
57
+ :class="`u-banner u-banner-${type} ${
58
+ !icon ? 'no-padding-label' : ''
59
+ } ${bordered}`"
48
60
  inline-actions
49
- :class="`u-banner u-banner-${type}`"
50
61
  tabindex="0"
51
62
  >
52
63
  <template v-slot:avatar>
53
64
  <q-icon
54
- aria-label="Banner Icon"
65
+ v-if="icon"
55
66
  :class="icon"
56
- size="1.5rem"
57
- :color="type"
58
67
  alt="Banner Info Icon"
68
+ aria-label="Banner Icon"
69
+ :color="type"
70
+ size="1.5rem"
59
71
  />
60
72
  </template>
61
73
  <span class="text-caption-lg">{{ message }}</span>
62
74
  <template v-slot:action>
63
75
  <u-btn-std
64
76
  v-if="primaryActionLabel"
77
+ :color="type"
65
78
  :flat="false"
66
79
  :label="primaryActionLabel"
67
- @onClick="handlePrimaryActionClick"
68
- :color="type"
69
80
  size="md"
81
+ @onClick="handlePrimaryActionClick"
70
82
  />
71
83
  <u-btn-std
72
- class="q-ml-sm"
73
- :outline="true"
74
84
  v-if="secondaryActionLabel"
75
- :label="secondaryActionLabel"
76
- @onClick="handleSecondaryActionClick"
85
+ class="q-ml-sm"
77
86
  :color="type"
87
+ :label="secondaryActionLabel"
88
+ :outline="true"
78
89
  size="md"
90
+ @onClick="handleSecondaryActionClick"
79
91
  />
80
92
  </template>
81
93
  </q-banner>
@@ -93,21 +105,38 @@ const handleSecondaryActionClick = () => {
93
105
 
94
106
  .u-banner-positive
95
107
  background: $green-1 !important
96
- color: $green-6 !important
108
+ color: $green-7 !important
109
+ &.bordered
110
+ border: 1.5px solid $green-7
97
111
 
98
112
  .u-banner-info
99
113
  background: $purple-1 !important
100
114
  color: $info !important
115
+ &.bordered
116
+ border: 1.5px solid $purple-7
101
117
 
102
118
  .u-banner-warning
103
119
  background: $orange-1 !important
104
120
  color: $orange-7 !important
121
+ &.bordered
122
+ border: 1.5px solid $orange-7
105
123
 
106
124
  .u-banner-accent
107
125
  background: $red-1 !important
108
126
  color: $red-7 !important
127
+ &.bordered
128
+ border: 1.5px solid $red-7
109
129
 
110
130
  .u-banner-primary
111
131
  background: $blue-1 !important
112
132
  color: $primary !important
133
+ &.bordered
134
+ border: 1.5px solid $primary
135
+
136
+ .no-padding-label
137
+ .q-banner__content
138
+ padding-left: 0px !important
139
+
140
+ .bordered
141
+ border-radius: $xs
113
142
  </style>
@@ -0,0 +1,67 @@
1
+ <script setup>
2
+ const props = defineProps({
3
+ align: {
4
+ type: String,
5
+ default: 'left',
6
+ },
7
+ links: {
8
+ type: Array,
9
+ default: () => [],
10
+ },
11
+ clickable: {
12
+ type: Boolean,
13
+ default: true,
14
+ },
15
+ showActiveRoute: {
16
+ type: Boolean,
17
+ default: true,
18
+ },
19
+ activeColor: {
20
+ type: String,
21
+ default: 'primary',
22
+ },
23
+ })
24
+ </script>
25
+ <template>
26
+ <q-breadcrumbs
27
+ gutter="none"
28
+ v-bind="$attrs"
29
+ class="u-breadcrumb"
30
+ :align="align"
31
+ :active-color="activeColor"
32
+ >
33
+ <q-breadcrumbs-el
34
+ v-for="(link, index) of links"
35
+ :key="index"
36
+ :label="link.label"
37
+ :to="link.to"
38
+ :class="`breadcrumb-label text-caption-lg ${
39
+ index === 0
40
+ ? 'q-mr-xs'
41
+ : index === links.length - 1
42
+ ? 'q-ml-xs'
43
+ : 'q-mx-xs'
44
+ } ${!showActiveRoute ? 'hide-active-route' : null} ${
45
+ !clickable ? 'non-clickable-route' : null
46
+ }`"
47
+ />
48
+ </q-breadcrumbs>
49
+ </template>
50
+ <style lang="sass">
51
+ .u-breadcrumb
52
+ .q-breadcrumbs__separator
53
+ font-size: 1rem
54
+ font-weight: 500
55
+ line-height: 1.25rem
56
+ letter-spacing: 0.03333rem
57
+
58
+ .q-router-link--active
59
+ cursor: default
60
+
61
+ .hide-active-route
62
+ color: $dark !important
63
+
64
+ .non-clickable-route
65
+ cursor: default !important
66
+ pointer-events: none
67
+ </style>
@@ -40,6 +40,10 @@ const props = defineProps({
40
40
  type: String,
41
41
  default: 'center end',
42
42
  },
43
+ offset: {
44
+ type: Array,
45
+ default: () => [4, 4],
46
+ },
43
47
  })
44
48
 
45
49
  const emit = defineEmits(['onClick'])
@@ -85,20 +89,23 @@ const btnClass = computed(() => {
85
89
  class="u-btn-icon"
86
90
  :class="`size-${size} ${btnClass}`"
87
91
  >
88
- <q-icon
89
- :color="iconColor"
90
- :aria-hidden="true"
91
- :class="`${iconClass} size-${size}`"
92
- :size="iconSize"
93
- />
94
-
95
- <UTooltip
96
- v-if="tooltip"
97
- :description="tooltip"
98
- :anchor="anchor"
99
- :self="self"
100
- :offset="[4, 4]"
101
- />
92
+ <template #default>
93
+ <q-icon
94
+ :color="iconColor"
95
+ :aria-hidden="true"
96
+ :class="`${iconClass} size-${size}`"
97
+ :size="iconSize"
98
+ />
99
+
100
+ <UTooltip
101
+ v-if="tooltip"
102
+ :description="tooltip"
103
+ :anchor="anchor"
104
+ :self="self"
105
+ :offset="offset"
106
+ />
107
+ <slot name="menu" />
108
+ </template>
102
109
  </q-btn>
103
110
  </template>
104
111
 
@@ -140,6 +147,9 @@ const btnClass = computed(() => {
140
147
  &.neutral-9
141
148
  color: $neutral-9
142
149
 
150
+ &.accent:hover
151
+ background: $accent-bg-hover
152
+
143
153
  .icon-tooltip
144
154
  background: $dark
145
155
  border-radius: $xxs
@@ -39,20 +39,12 @@ const props = defineProps({
39
39
  },
40
40
  })
41
41
 
42
- const emit = defineEmits(['click'])
42
+ const emit = defineEmits(['onClick'])
43
43
 
44
44
  const handleClick = () => {
45
45
  return emit('onClick')
46
46
  }
47
47
 
48
- const paddingClass = computed(() => {
49
- if (props.size === 'sm') {
50
- return 'q-px-sm'
51
- }
52
-
53
- return 'q-px-ba'
54
- })
55
-
56
48
  const textClass = computed(() => {
57
49
  if (props.color === 'neutral') {
58
50
  return 'text-neutral-9'
@@ -71,7 +63,7 @@ const isFullWidth = computed(() => {
71
63
  <template>
72
64
  <q-btn
73
65
  class="u-btn q-py-none"
74
- :class="`size-${size} ${paddingClass} ${textClass} focus-${color} ${isFullWidth}`"
66
+ :class="`size-${size} ${textClass} focus-${color} ${isFullWidth}`"
75
67
  :color="color"
76
68
  :disable="disable"
77
69
  :unelevated="!outline"
@@ -80,45 +72,57 @@ const isFullWidth = computed(() => {
80
72
  :flat="flat"
81
73
  @click="handleClick"
82
74
  >
83
- <div class="row items-center no-wrap">
84
- <q-icon
85
- v-if="leftIcon"
86
- left
87
- :class="leftIcon"
88
- class="q-mr-xs"
89
- size="1.25rem"
90
- />
91
-
92
- <div class="text-center text-caption-md button-label">
93
- {{ label }}
94
- </div>
95
- <q-icon
96
- v-if="rightIcon"
97
- right
98
- :class="rightIcon"
99
- class="q-ml-xs"
100
- size="1.25rem"
101
- />
102
- </div>
75
+ <template #default>
76
+ <slot name="default">
77
+ <div class="row items-center no-wrap">
78
+ <q-icon
79
+ v-if="leftIcon"
80
+ left
81
+ :class="leftIcon"
82
+ class="q-mr-xs"
83
+ size="1rem"
84
+ />
85
+
86
+ <div class="text-center text-caption-md button-label">
87
+ {{ label }}
88
+ </div>
89
+ <q-icon
90
+ v-if="rightIcon"
91
+ right
92
+ :class="rightIcon"
93
+ class="q-ml-xs"
94
+ size="1rem"
95
+ />
96
+ </div>
97
+ </slot>
98
+
99
+ <slot name="tooltip" />
100
+ <slot name="menu" />
101
+ </template>
103
102
  </q-btn>
104
103
  </template>
105
104
 
106
105
  <style lang="sass">
107
106
  .u-btn
108
107
  border-radius: $xs
109
- min-width: 5.5rem
108
+ min-width: 5.5rem !important
110
109
 
111
110
  &.bg-neutral
112
111
  background-color: $neutral-3
113
112
 
114
113
  &.size-sm
115
114
  min-height: $md
115
+ padding: 0 $sm !important
116
116
 
117
117
  &.size-md
118
118
  min-height: $lg
119
+ padding: 0 $ba !important
120
+
119
121
 
120
122
  &.size-lg
121
123
  min-height: $xl
124
+ padding: 0 $ba !important
125
+
122
126
 
123
127
  .button-label
124
128
  word-break: break-all