@flux-ui/components 3.0.0-next.0

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 (261) hide show
  1. package/README.md +45 -0
  2. package/package.json +77 -0
  3. package/src/component/FluxAction.vue +27 -0
  4. package/src/component/FluxActionBar.vue +94 -0
  5. package/src/component/FluxActionPane.vue +40 -0
  6. package/src/component/FluxActions.vue +27 -0
  7. package/src/component/FluxAlert.vue +37 -0
  8. package/src/component/FluxAnimatedColors.vue +141 -0
  9. package/src/component/FluxAspectRatio.vue +21 -0
  10. package/src/component/FluxAutoGrid.vue +27 -0
  11. package/src/component/FluxAvatar.vue +119 -0
  12. package/src/component/FluxBadge.vue +84 -0
  13. package/src/component/FluxBadgeStack.vue +18 -0
  14. package/src/component/FluxBorderShine.vue +36 -0
  15. package/src/component/FluxBoxedIcon.vue +36 -0
  16. package/src/component/FluxButton.vue +110 -0
  17. package/src/component/FluxButtonGroup.vue +15 -0
  18. package/src/component/FluxButtonStack.vue +28 -0
  19. package/src/component/FluxCalendar.vue +254 -0
  20. package/src/component/FluxCalendarEvent.vue +41 -0
  21. package/src/component/FluxCheckbox.vue +60 -0
  22. package/src/component/FluxChip.vue +57 -0
  23. package/src/component/FluxClickablePane.vue +61 -0
  24. package/src/component/FluxColorPicker.vue +265 -0
  25. package/src/component/FluxColorSelect.vue +81 -0
  26. package/src/component/FluxComment.vue +71 -0
  27. package/src/component/FluxConfirm.vue +42 -0
  28. package/src/component/FluxContainer.vue +23 -0
  29. package/src/component/FluxDataTable.vue +96 -0
  30. package/src/component/FluxDatePicker.vue +353 -0
  31. package/src/component/FluxDestructiveButton.vue +28 -0
  32. package/src/component/FluxDisabled.vue +22 -0
  33. package/src/component/FluxDivider.vue +37 -0
  34. package/src/component/FluxDotPattern.vue +72 -0
  35. package/src/component/FluxDropZone.vue +202 -0
  36. package/src/component/FluxDynamicView.vue +16 -0
  37. package/src/component/FluxExpandable.vue +119 -0
  38. package/src/component/FluxExpandableGroup.vue +53 -0
  39. package/src/component/FluxFader.vue +64 -0
  40. package/src/component/FluxFaderItem.vue +15 -0
  41. package/src/component/FluxFilter.vue +133 -0
  42. package/src/component/FluxFilterDate.vue +58 -0
  43. package/src/component/FluxFilterDateRange.vue +59 -0
  44. package/src/component/FluxFilterOption.vue +49 -0
  45. package/src/component/FluxFilterOptionAsync.vue +103 -0
  46. package/src/component/FluxFilterOptions.vue +62 -0
  47. package/src/component/FluxFilterOptionsAsync.vue +113 -0
  48. package/src/component/FluxFilterRange.vue +91 -0
  49. package/src/component/FluxFlickeringGrid.vue +141 -0
  50. package/src/component/FluxFlyout.vue +205 -0
  51. package/src/component/FluxFocalPointEditor.vue +137 -0
  52. package/src/component/FluxFocalPointImage.vue +29 -0
  53. package/src/component/FluxForm.vue +35 -0
  54. package/src/component/FluxFormColumn.vue +15 -0
  55. package/src/component/FluxFormDateInput.vue +92 -0
  56. package/src/component/FluxFormDateRangeInput.vue +87 -0
  57. package/src/component/FluxFormDateTimeInput.vue +120 -0
  58. package/src/component/FluxFormField.vue +98 -0
  59. package/src/component/FluxFormFieldAddition.vue +37 -0
  60. package/src/component/FluxFormInput.vue +223 -0
  61. package/src/component/FluxFormInputAddition.vue +31 -0
  62. package/src/component/FluxFormInputGroup.vue +25 -0
  63. package/src/component/FluxFormPinInput.vue +135 -0
  64. package/src/component/FluxFormRangeSlider.vue +179 -0
  65. package/src/component/FluxFormRow.vue +15 -0
  66. package/src/component/FluxFormSection.vue +23 -0
  67. package/src/component/FluxFormSelect.vue +59 -0
  68. package/src/component/FluxFormSelectAsync.vue +118 -0
  69. package/src/component/FluxFormSlider.vue +123 -0
  70. package/src/component/FluxFormTextArea.vue +53 -0
  71. package/src/component/FluxFormTimeZonePicker.vue +713 -0
  72. package/src/component/FluxGallery.vue +99 -0
  73. package/src/component/FluxGalleryItem.vue +49 -0
  74. package/src/component/FluxGrid.vue +28 -0
  75. package/src/component/FluxGridColumn.vue +31 -0
  76. package/src/component/FluxGridPattern.vue +60 -0
  77. package/src/component/FluxIcon.vue +79 -0
  78. package/src/component/FluxInfo.vue +28 -0
  79. package/src/component/FluxInfoStack.vue +17 -0
  80. package/src/component/FluxLegend.vue +27 -0
  81. package/src/component/FluxLink.vue +35 -0
  82. package/src/component/FluxMenu.vue +31 -0
  83. package/src/component/FluxMenuGroup.vue +21 -0
  84. package/src/component/FluxMenuItem.vue +84 -0
  85. package/src/component/FluxMenuOptions.vue +38 -0
  86. package/src/component/FluxMenuSubHeader.vue +33 -0
  87. package/src/component/FluxMenuTitle.vue +17 -0
  88. package/src/component/FluxNotice.vue +79 -0
  89. package/src/component/FluxNoticeStack.vue +17 -0
  90. package/src/component/FluxOverlay.vue +31 -0
  91. package/src/component/FluxPagination.vue +148 -0
  92. package/src/component/FluxPaginationBar.vue +81 -0
  93. package/src/component/FluxPane.vue +45 -0
  94. package/src/component/FluxPaneBody.vue +15 -0
  95. package/src/component/FluxPaneDeck.vue +24 -0
  96. package/src/component/FluxPaneFooter.vue +15 -0
  97. package/src/component/FluxPaneGroup.vue +15 -0
  98. package/src/component/FluxPaneHeader.vue +44 -0
  99. package/src/component/FluxPaneIllustration.vue +68 -0
  100. package/src/component/FluxPaneMedia.vue +31 -0
  101. package/src/component/FluxPercentageBar.vue +45 -0
  102. package/src/component/FluxPersona.vue +48 -0
  103. package/src/component/FluxPlaceholder.vue +56 -0
  104. package/src/component/FluxPressable.vue +77 -0
  105. package/src/component/FluxPrimaryButton.vue +28 -0
  106. package/src/component/FluxProgressBar.vue +75 -0
  107. package/src/component/FluxPrompt.vue +77 -0
  108. package/src/component/FluxPublishButton.vue +59 -0
  109. package/src/component/FluxQuantitySelector.vue +109 -0
  110. package/src/component/FluxRemove.vue +34 -0
  111. package/src/component/FluxRoot.vue +60 -0
  112. package/src/component/FluxSecondaryButton.vue +28 -0
  113. package/src/component/FluxSegmentedControl.vue +77 -0
  114. package/src/component/FluxSegmentedView.vue +15 -0
  115. package/src/component/FluxSeparator.vue +19 -0
  116. package/src/component/FluxSlideOver.vue +25 -0
  117. package/src/component/FluxSnackbar.vue +154 -0
  118. package/src/component/FluxSnackbarProvider.vue +34 -0
  119. package/src/component/FluxSpacer.vue +9 -0
  120. package/src/component/FluxSpacing.vue +32 -0
  121. package/src/component/FluxSpinner.vue +48 -0
  122. package/src/component/FluxSplitButton.vue +61 -0
  123. package/src/component/FluxStack.vue +40 -0
  124. package/src/component/FluxStatistic.vue +68 -0
  125. package/src/component/FluxStepper.vue +69 -0
  126. package/src/component/FluxStepperStep.vue +15 -0
  127. package/src/component/FluxStepperSteps.vue +62 -0
  128. package/src/component/FluxTab.vue +23 -0
  129. package/src/component/FluxTabBar.vue +87 -0
  130. package/src/component/FluxTabBarItem.vue +104 -0
  131. package/src/component/FluxTable.vue +68 -0
  132. package/src/component/FluxTableActions.vue +16 -0
  133. package/src/component/FluxTableCell.vue +47 -0
  134. package/src/component/FluxTableHeader.vue +111 -0
  135. package/src/component/FluxTableRow.vue +15 -0
  136. package/src/component/FluxTabs.vue +91 -0
  137. package/src/component/FluxTag.vue +85 -0
  138. package/src/component/FluxTagStack.vue +18 -0
  139. package/src/component/FluxTicks.vue +44 -0
  140. package/src/component/FluxTimeline.vue +17 -0
  141. package/src/component/FluxTimelineItem.vue +73 -0
  142. package/src/component/FluxToggle.vue +64 -0
  143. package/src/component/FluxToolbar.vue +32 -0
  144. package/src/component/FluxToolbarGroup.vue +18 -0
  145. package/src/component/FluxTooltip.vue +56 -0
  146. package/src/component/FluxTooltipProvider.vue +176 -0
  147. package/src/component/FluxWindow.vue +47 -0
  148. package/src/component/index.ts +142 -0
  149. package/src/component/primitive/Anchor.vue +17 -0
  150. package/src/component/primitive/AnchorPopup.vue +194 -0
  151. package/src/component/primitive/CoordinatePicker.vue +155 -0
  152. package/src/component/primitive/CoordinatePickerThumb.vue +71 -0
  153. package/src/component/primitive/FilterItem.vue +44 -0
  154. package/src/component/primitive/FilterMenuRenderer.ts +233 -0
  155. package/src/component/primitive/FilterOptionBase.vue +67 -0
  156. package/src/component/primitive/SelectBase.vue +340 -0
  157. package/src/component/primitive/SliderBase.vue +89 -0
  158. package/src/component/primitive/SliderThumb.vue +64 -0
  159. package/src/component/primitive/SliderTrack.vue +22 -0
  160. package/src/component/primitive/VNodeRenderer.ts +11 -0
  161. package/src/component/primitive/index.ts +10 -0
  162. package/src/composable/index.ts +9 -0
  163. package/src/composable/private/index.ts +3 -0
  164. package/src/composable/private/useFormSelect.ts +66 -0
  165. package/src/composable/private/useLoaded.ts +21 -0
  166. package/src/composable/private/useTranslate.ts +35 -0
  167. package/src/composable/useBreakpoints.ts +54 -0
  168. package/src/composable/useDisabled.ts +9 -0
  169. package/src/composable/useDisabledInjection.ts +6 -0
  170. package/src/composable/useExpandableGroupInjection.ts +10 -0
  171. package/src/composable/useFilterInjection.ts +22 -0
  172. package/src/composable/useFlyoutInjection.ts +10 -0
  173. package/src/composable/useFormFieldInjection.ts +8 -0
  174. package/src/composable/useTableInjection.ts +11 -0
  175. package/src/css/base.scss +33 -0
  176. package/src/css/component/Action.module.scss +107 -0
  177. package/src/css/component/Avatar.module.scss +177 -0
  178. package/src/css/component/Badge.module.scss +189 -0
  179. package/src/css/component/Button.module.scss +293 -0
  180. package/src/css/component/Calendar.module.scss +171 -0
  181. package/src/css/component/Chip.module.scss +58 -0
  182. package/src/css/component/Color.module.scss +184 -0
  183. package/src/css/component/Comment.module.scss +123 -0
  184. package/src/css/component/DatePicker.module.scss +193 -0
  185. package/src/css/component/Divider.module.scss +79 -0
  186. package/src/css/component/DropZone.module.scss +99 -0
  187. package/src/css/component/Expandable.module.scss +112 -0
  188. package/src/css/component/Fader.module.scss +38 -0
  189. package/src/css/component/Filter.module.scss +80 -0
  190. package/src/css/component/Flyout.module.scss +63 -0
  191. package/src/css/component/FocalPoint.module.scss +84 -0
  192. package/src/css/component/Form.module.scss +812 -0
  193. package/src/css/component/Gallery.module.scss +64 -0
  194. package/src/css/component/Grid.module.scss +24 -0
  195. package/src/css/component/Icon.module.scss +104 -0
  196. package/src/css/component/Info.module.scss +15 -0
  197. package/src/css/component/Layout.module.scss +63 -0
  198. package/src/css/component/Legend.module.scss +32 -0
  199. package/src/css/component/Menu.module.scss +314 -0
  200. package/src/css/component/Notice.module.scss +279 -0
  201. package/src/css/component/Overlay.module.scss +149 -0
  202. package/src/css/component/Pagination.module.scss +59 -0
  203. package/src/css/component/Pane.module.scss +218 -0
  204. package/src/css/component/PercentageBar.module.scss +31 -0
  205. package/src/css/component/Placeholder.module.scss +72 -0
  206. package/src/css/component/Progress.module.scss +84 -0
  207. package/src/css/component/Remove.module.scss +29 -0
  208. package/src/css/component/Root.module.scss +8 -0
  209. package/src/css/component/SegmentedControl.module.scss +82 -0
  210. package/src/css/component/Snackbar.module.scss +227 -0
  211. package/src/css/component/Spinner.module.scss +36 -0
  212. package/src/css/component/Statistic.module.scss +118 -0
  213. package/src/css/component/Stepper.module.scss +103 -0
  214. package/src/css/component/Tab.module.scss +162 -0
  215. package/src/css/component/Table.module.scss +164 -0
  216. package/src/css/component/Timeline.module.scss +173 -0
  217. package/src/css/component/Toolbar.module.scss +82 -0
  218. package/src/css/component/Tooltip.module.scss +62 -0
  219. package/src/css/component/Transition.module.scss +142 -0
  220. package/src/css/component/Visual.module.scss +70 -0
  221. package/src/css/component/base/Button.module.scss +87 -0
  222. package/src/css/component/base/Effect.module.scss +139 -0
  223. package/src/css/component/base/Grid.module.scss +8 -0
  224. package/src/css/component/base/Pane.module.scss +54 -0
  225. package/src/css/component/primitive/CoordinatePicker.module.scss +24 -0
  226. package/src/css/component/primitive/Slider.module.scss +116 -0
  227. package/src/css/index.scss +5 -0
  228. package/src/css/layers.scss +1 -0
  229. package/src/css/mixin/breakpoints.scss +112 -0
  230. package/src/css/mixin/focus-ring.scss +56 -0
  231. package/src/css/mixin/hover.scss +7 -0
  232. package/src/css/mixin/index.scss +3 -0
  233. package/src/css/reset.scss +169 -0
  234. package/src/css/typography.scss +87 -0
  235. package/src/css/variables.scss +214 -0
  236. package/src/data/di.ts +42 -0
  237. package/src/data/filter.ts +9 -0
  238. package/src/data/helper.ts +9 -0
  239. package/src/data/i18n.ts +55 -0
  240. package/src/data/iconRegistry.ts +21 -0
  241. package/src/data/index.ts +8 -0
  242. package/src/data/inputMask.ts +34 -0
  243. package/src/data/store.ts +233 -0
  244. package/src/image/avatar-mask.svg +3 -0
  245. package/src/index.ts +25 -0
  246. package/src/transition/FluxAutoHeightTransition.vue +59 -0
  247. package/src/transition/FluxAutoWidthTransition.vue +59 -0
  248. package/src/transition/FluxBreakthroughTransition.vue +23 -0
  249. package/src/transition/FluxFadeTransition.vue +24 -0
  250. package/src/transition/FluxOverlayTransition.vue +22 -0
  251. package/src/transition/FluxRouteTransition.vue +23 -0
  252. package/src/transition/FluxSlideOverTransition.vue +22 -0
  253. package/src/transition/FluxTooltipTransition.vue +22 -0
  254. package/src/transition/FluxVerticalWindowTransition.vue +23 -0
  255. package/src/transition/FluxWindowTransition.vue +23 -0
  256. package/src/transition/index.ts +10 -0
  257. package/src/util/createDialogRenderer.ts +64 -0
  258. package/src/util/createLabelForDateRange.ts +61 -0
  259. package/src/util/index.ts +2 -0
  260. package/src/vite.d.ts +13 -0
  261. package/tsconfig.json +45 -0
@@ -0,0 +1,72 @@
1
+ @use '$flux/css/mixin';
2
+
3
+ .placeholder {
4
+ position: relative;
5
+ display: flex;
6
+ align-items: center;
7
+ flex: 1 1 0;
8
+ flex-flow: column;
9
+ justify-content: center;
10
+ background: rgb(var(--gray-1));
11
+ border: 1px dashed rgb(var(--gray-3));
12
+ border-radius: var(--radius);
13
+ text-align: center;
14
+ user-select: none;
15
+
16
+ &.isButton {
17
+ cursor: pointer;
18
+
19
+ @include mixin.hover {
20
+ background: rgb(var(--gray-2));
21
+ }
22
+ }
23
+
24
+ &.isExtended {
25
+ padding: 27px;
26
+ gap: 9px;
27
+
28
+ .placeholderIcon {
29
+ font-size: 24px;
30
+ }
31
+ }
32
+
33
+ &.isSimple {
34
+ padding: 18px;
35
+ }
36
+
37
+ &.isSmall {
38
+ padding: 12px;
39
+ font-size: 12px;
40
+
41
+ .placeholderCaption :is(strong) {
42
+ color: var(--foreground-secondary);
43
+ font-weight: 400;
44
+ }
45
+
46
+ .placeholderIcon {
47
+ color: var(--foreground-secondary);
48
+ }
49
+ }
50
+
51
+ :local(.button) {
52
+ align-self: center;
53
+ }
54
+ }
55
+
56
+ .placeholderCaption {
57
+ display: flex;
58
+ align-items: stretch;
59
+ flex-flow: column;
60
+
61
+ :is(p) {
62
+ margin: 0;
63
+ max-width: 510px;
64
+ color: var(--foreground-secondary);
65
+ font-size: 14px;
66
+ }
67
+ }
68
+
69
+ .placeholderIcon {
70
+ color: rgb(var(--primary-7));
71
+ font-size: 20px;
72
+ }
@@ -0,0 +1,84 @@
1
+ @value basePaneStructure from './base/Pane.module.scss';
2
+
3
+ .progressBar {
4
+ position: relative;
5
+ }
6
+
7
+ .progressBarTrack {
8
+ position: relative;
9
+ height: 9px;
10
+ background: rgb(var(--gray-2));
11
+ border-radius: calc(var(--radius) / 2);
12
+ box-shadow: inset 0 0 0 1px rgb(var(--gray-3));
13
+ contain: paint;
14
+ }
15
+
16
+ .progressBarValue {
17
+ position: absolute;
18
+ top: 0;
19
+ left: 0;
20
+ height: inherit;
21
+ background: linear-gradient(to right, rgb(var(--primary-8)) 20%, rgb(var(--primary-6)), rgb(var(--primary-8)) 80%);
22
+ background-size: 150px 100%;
23
+ border-radius: inherit;
24
+ animation: progressBarValue 1s linear infinite;
25
+ }
26
+
27
+ .progressBarTrackIndeterminate {
28
+ composes: progressBarTrack;
29
+
30
+ .progressBarValue {
31
+ background: linear-gradient(to right, rgb(var(--primary-8)) 20%, rgb(var(--primary-6)), rgb(var(--primary-8)) 80%);
32
+ background-size: 90px 100%;
33
+ animation: progressBarIndeterminate 1s linear infinite;
34
+ }
35
+ }
36
+
37
+ .progressBarInfo {
38
+ display: flex;
39
+ gap: 21px;
40
+ justify-content: flex-end;
41
+ font-size: 14px;
42
+ }
43
+
44
+ .progressBarProgress {
45
+ flex-shrink: 0;
46
+ font-variant-numeric: tabular-nums;
47
+ font-weight: 500;
48
+ }
49
+
50
+ .progressBarStatus {
51
+ margin-right: auto;
52
+ color: var(--foreground-secondary);
53
+ overflow: hidden;
54
+ text-overflow: ellipsis;
55
+ white-space: nowrap;
56
+ }
57
+
58
+ :local(.basePaneStructure) > .progressBar:first-child {
59
+ margin: 9px 9px 0;
60
+ }
61
+
62
+ :local(.basePaneStructure) > .progressBar:last-child {
63
+ margin: 0 9px 9px;
64
+ }
65
+
66
+ @keyframes progressBarIndeterminate {
67
+ from {
68
+ background-position-x: 90px;
69
+ }
70
+
71
+ to {
72
+ background-position-x: -90px;
73
+ }
74
+ }
75
+
76
+ @keyframes progressBarValue {
77
+ from {
78
+ background-position-x: -150px;
79
+ }
80
+
81
+ to {
82
+ background-position-x: 150px;
83
+ }
84
+ }
@@ -0,0 +1,29 @@
1
+ @use '$flux/css/mixin';
2
+
3
+ .remove {
4
+ position: absolute;
5
+ display: flex;
6
+ top: -9px;
7
+ right: -9px;
8
+ height: 27px;
9
+ width: 27px;
10
+ align-items: center;
11
+ justify-content: center;
12
+ background: rgb(var(--danger-7));
13
+ border: 3px solid rgb(var(--gray-0));
14
+ border-radius: 99px;
15
+ color: rgb(var(--danger-0));
16
+ cursor: pointer;
17
+ transition: 300ms var(--swift-out);
18
+ transition-property: background, opacity, scale;
19
+
20
+ @include mixin.hover {
21
+ background: rgb(var(--danger-8));
22
+ }
23
+
24
+ &.isHidden {
25
+ opacity: 0;
26
+ pointer-events: none;
27
+ scale: .5;
28
+ }
29
+ }
@@ -0,0 +1,8 @@
1
+ .root {
2
+ display: contents;
3
+
4
+ &.isLocked {
5
+ cursor: default;
6
+ overflow: hidden;
7
+ }
8
+ }
@@ -0,0 +1,82 @@
1
+ @use '$flux/css/mixin';
2
+
3
+ .segmentedControl {
4
+ position: relative;
5
+ align-items: center;
6
+ gap: 1px;
7
+ background: rgb(var(--gray-1));
8
+ border: 1px solid rgb(var(--gray-2));
9
+ border-radius: var(--radius);
10
+ }
11
+
12
+ .segmentedControlFill {
13
+ composes: segmentedControl;
14
+
15
+ display: flex;
16
+ }
17
+
18
+ .segmentedControlInline {
19
+ composes: segmentedControl;
20
+
21
+ display: inline-flex;
22
+ width: min-content;
23
+ }
24
+
25
+ .segmentedControlHighlight {
26
+ position: absolute;
27
+ top: 0;
28
+ bottom: 0;
29
+ background: rgb(var(--gray-0));
30
+ border-radius: var(--radius);
31
+ box-shadow: var(--shadow-sm);
32
+ outline: 1px solid rgb(var(--gray-3));
33
+ pointer-events: none;
34
+ transition: 300ms var(--swift-out);
35
+ transition-property: left, width;
36
+ }
37
+
38
+ .segmentedControlItem {
39
+ display: flex;
40
+ height: 36px;
41
+ padding-left: 12px;
42
+ padding-right: 12px;
43
+ align-items: center;
44
+ flex: 1 1 0;
45
+ gap: 9px;
46
+ justify-content: center;
47
+ background: none;
48
+ border: 0;
49
+ border-radius: calc(var(--radius) - 3px);
50
+ color: var(--foreground);
51
+ cursor: pointer;
52
+ font-weight: 500;
53
+ text-align: center;
54
+ transition: 300ms var(--swift-out);
55
+ transition-property: background, color;
56
+
57
+ @include mixin.hover {
58
+ background: rgb(var(--gray-2));
59
+ }
60
+
61
+ &.isActive {
62
+ background: none;
63
+ color: var(--foreground-prominent);
64
+ cursor: default;
65
+ }
66
+
67
+ > * {
68
+ position: relative;
69
+ }
70
+ }
71
+
72
+ .segmentedControlSeparator {
73
+ height: 15px;
74
+ width: 1px;
75
+ flex-shrink: 0;
76
+ background: rgb(var(--gray-3));
77
+ transition: opacity 300ms var(--swift-out);
78
+
79
+ &.isActive {
80
+ opacity: 0;
81
+ }
82
+ }
@@ -0,0 +1,227 @@
1
+ @use '$flux/css/mixin';
2
+
3
+ @value basePane from './base/Pane.module.scss';
4
+
5
+ .snackbar {
6
+ composes: basePane;
7
+
8
+ display: flex;
9
+ box-shadow: var(--shadow-xl), var(--shadow-2xl);
10
+ overflow: hidden;
11
+
12
+ .action {
13
+ margin: 12px 12px 12px 0;
14
+ }
15
+
16
+ .progressBar {
17
+ margin-top: 9px;
18
+
19
+ &:not(:last-child) {
20
+ margin-bottom: 6px;
21
+ }
22
+ }
23
+
24
+ .progressBarTrack {
25
+ height: 6px;
26
+ }
27
+ }
28
+
29
+ .snackbarContent {
30
+ display: flex;
31
+ padding: 15px 18px;
32
+ align-items: flex-start;
33
+ flex-grow: 1;
34
+ gap: 15px;
35
+
36
+ > .icon,
37
+ > .spinner {
38
+ flex-shrink: 0;
39
+ translate: 0 3px;
40
+ }
41
+ }
42
+
43
+ .snackbarBody {
44
+ display: flex;
45
+ align-self: stretch;
46
+ flex-flow: column;
47
+ flex-grow: 1;
48
+ }
49
+
50
+ .snackbarMessage {
51
+ color: var(--foreground);
52
+ }
53
+
54
+ .snackbarSubMessage {
55
+ color: var(--foreground-secondary);
56
+ font-size: 14px;
57
+ }
58
+
59
+ .snackbarTitle {
60
+ font-weight: 500;
61
+ }
62
+
63
+ .snackbarAction {
64
+ display: flex;
65
+ padding: 6px 15px;
66
+ min-width: 84px;
67
+ align-items: center;
68
+ justify-content: center;
69
+ flex-grow: 1;
70
+ background: rgb(var(--gray-0));
71
+ border: 0;
72
+ border-radius: 0;
73
+ color: var(--foreground);
74
+ cursor: pointer;
75
+ font-size: 14px;
76
+ font-weight: 500;
77
+ outline: 0;
78
+ text-align: center;
79
+ transition: 180ms var(--swift-out);
80
+ transition-property: background, color;
81
+
82
+ &:hover {
83
+ background: rgb(var(--gray-1));
84
+ color: var(--foreground-prominent);
85
+ }
86
+
87
+ &:active {
88
+ background: rgb(var(--gray-2));
89
+ }
90
+ }
91
+
92
+ .snackbarActions {
93
+ display: flex;
94
+ padding-left: 1px;
95
+ flex-flow: column;
96
+ flex-grow: 1;
97
+ gap: 1px;
98
+ background: rgb(var(--gray-2));
99
+ }
100
+
101
+ .snackbarGray {
102
+ composes: snackbar;
103
+
104
+ .snackbarAction:first-child,
105
+ .snackbarContent > .icon,
106
+ .snackbarTitle {
107
+ color: var(--foreground-prominent);
108
+ }
109
+ }
110
+
111
+ .snackbarPrimary {
112
+ composes: snackbar;
113
+
114
+ .snackbarAction:first-child,
115
+ .snackbarContent > .icon,
116
+ .snackbarTitle {
117
+ color: rgb(var(--primary-7));
118
+ }
119
+
120
+ .spinnerEffect,
121
+ .spinnerValue {
122
+ stroke: rgb(var(--primary-8));
123
+ }
124
+ }
125
+
126
+ .snackbarDanger {
127
+ composes: snackbar;
128
+
129
+ .snackbarAction:first-child,
130
+ .snackbarContent > .icon,
131
+ .snackbarTitle {
132
+ color: rgb(var(--danger-7));
133
+ }
134
+
135
+ .spinnerEffect,
136
+ .spinnerValue {
137
+ stroke: rgb(var(--danger-8));
138
+ }
139
+ }
140
+
141
+ .snackbarInfo {
142
+ composes: snackbar;
143
+
144
+ .snackbarAction:first-child,
145
+ .snackbarContent > .icon,
146
+ .snackbarTitle {
147
+ color: rgb(var(--info-7));
148
+ }
149
+
150
+ .spinnerEffect,
151
+ .spinnerValue {
152
+ stroke: rgb(var(--info-8));
153
+ }
154
+ }
155
+
156
+ .snackbarSuccess {
157
+ composes: snackbar;
158
+
159
+ .snackbarAction:first-child,
160
+ .snackbarContent > .icon,
161
+ .snackbarTitle {
162
+ color: rgb(var(--success-7));
163
+ }
164
+
165
+ .spinnerEffect,
166
+ .spinnerValue {
167
+ stroke: rgb(var(--success-8));
168
+ }
169
+ }
170
+
171
+ .snackbarWarning {
172
+ composes: snackbar;
173
+
174
+ .snackbarAction:first-child,
175
+ .snackbarContent > .icon,
176
+ .snackbarTitle {
177
+ color: rgb(var(--warning-7));
178
+ }
179
+
180
+ .spinnerEffect,
181
+ .spinnerValue {
182
+ stroke: rgb(var(--warning-8));
183
+ }
184
+ }
185
+
186
+ .snackbars {
187
+ position: fixed;
188
+ display: flex;
189
+ flex-flow: column;
190
+ gap: 15px;
191
+ z-index: 100000;
192
+
193
+ @include mixin.breakpoint-down(sm) {
194
+ left: 15px;
195
+ right: 15px;
196
+ bottom: 15px;
197
+ }
198
+
199
+ @include mixin.breakpoint-up(md) {
200
+ width: 540px;
201
+ top: 30px;
202
+ left: calc(50dvw - 270px);
203
+ }
204
+ }
205
+
206
+ .snackbarsEnterActive,
207
+ .snackbarsLeaveActive,
208
+ .snackbarsMove {
209
+ transition: 420ms var(--swift-out);
210
+ }
211
+
212
+ .snackbarsLeaveActive {
213
+ position: absolute;
214
+ width: 100%;
215
+ }
216
+
217
+ .snackbarsEnterFrom {
218
+ opacity: 0;
219
+ transform: translate3d(0, -15px, 0);
220
+ }
221
+
222
+ .snackbarsLeaveTo {
223
+ opacity: 0;
224
+ scale: .95;
225
+ translate: 0 -15px;
226
+ z-index: -1;
227
+ }
@@ -0,0 +1,36 @@
1
+ .spinner {
2
+ --track: rgb(var(--gray-2));
3
+ --value: rgb(var(--primary-7));
4
+
5
+ display: inline-block;
6
+ height: 1em;
7
+ width: 1em;
8
+ flex: 0 0 1em;
9
+ animation: spinner 5s linear infinite;
10
+ font-size: 20px;
11
+ }
12
+
13
+ .spinnerTrack {
14
+ stroke: var(--track);
15
+ }
16
+
17
+ .spinnerEffect,
18
+ .spinnerValue {
19
+ stroke: var(--value);
20
+ transform-origin: center;
21
+ animation: spinner 1.2s var(--swift-out) infinite;
22
+ }
23
+
24
+ .spinnerEffect {
25
+ opacity: .25;
26
+ animation-delay: -1.05s;
27
+ }
28
+
29
+ @keyframes spinner {
30
+ from {
31
+ transform: rotate(0deg);
32
+ }
33
+ to {
34
+ transform: rotate(1turn);
35
+ }
36
+ }
@@ -0,0 +1,118 @@
1
+ .statistic {
2
+ padding: 21px;
3
+ gap: 21px;
4
+
5
+ &.isGray .statisticIcon {
6
+ background: rgb(var(--gray-2));
7
+ color: rgb(var(--gray-7));
8
+ }
9
+
10
+ &.isPrimary .statisticIcon {
11
+ background: rgb(var(--primary-2));
12
+ color: rgb(var(--primary-7));
13
+ }
14
+
15
+ &.isDanger .statisticIcon {
16
+ background: rgb(var(--danger-2));
17
+ color: rgb(var(--danger-7));
18
+ }
19
+
20
+ &.isInfo .statisticIcon {
21
+ background: rgb(var(--info-2));
22
+ color: rgb(var(--info-7));
23
+ }
24
+
25
+ &.isSuccess .statisticIcon {
26
+ background: rgb(var(--success-2));
27
+ color: rgb(var(--success-7));
28
+ }
29
+
30
+ &.isWarning .statisticIcon {
31
+ background: rgb(var(--warning-2));
32
+ color: rgb(var(--warning-7));
33
+ }
34
+ }
35
+
36
+ .statisticChange {
37
+ display: flex;
38
+ align-items: center;
39
+ align-self: flex-end;
40
+ gap: 6px;
41
+ font-size: 12px;
42
+ font-weight: 600;
43
+ line-height: 1;
44
+
45
+ &.isGray {
46
+ color: var(--foreground-prominent);
47
+ }
48
+
49
+ &.isPrimary {
50
+ color: rgb(var(--primary-7));
51
+ }
52
+
53
+ &.isDanger {
54
+ color: rgb(var(--danger-7));
55
+ }
56
+
57
+ &.isInfo {
58
+ color: rgb(var(--info-7));
59
+ }
60
+
61
+ &.isSuccess {
62
+ color: rgb(var(--success-7));
63
+ }
64
+
65
+ &.isWarning {
66
+ color: rgb(var(--warning-7));
67
+ }
68
+ }
69
+
70
+ .statisticData {
71
+ display: flex;
72
+ flex-flow: column;
73
+ flex-grow: 1;
74
+ gap: 9px;
75
+ line-height: 1;
76
+
77
+ :is(span) {
78
+ color: var(--foreground-secondary);
79
+ }
80
+
81
+ :is(strong) {
82
+ color: var(--foreground-prominent);
83
+ font-size: 24px;
84
+ font-weight: 700;
85
+ }
86
+ }
87
+
88
+ .statisticIcon {
89
+ display: flex;
90
+ height: 48px;
91
+ width: 48px;
92
+ align-items: center;
93
+ justify-content: center;
94
+ border-radius: var(--radius);
95
+ }
96
+
97
+ .statisticHorizontal {
98
+ composes: statistic;
99
+
100
+ display: flex;
101
+ }
102
+
103
+ .statisticVertical {
104
+ composes: statistic;
105
+
106
+ display: flex;
107
+ align-items: center;
108
+ flex-flow: column;
109
+ text-align: center;
110
+
111
+ .statisticChange {
112
+ align-self: center;
113
+ }
114
+
115
+ .statisticData {
116
+ align-items: center;
117
+ }
118
+ }