tide-design-system 2.0.22 → 2.0.23
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.
- package/.eslintrc.cjs +90 -0
- package/.storybook/main.ts +60 -0
- package/.storybook/preview.ts +252 -0
- package/dist/css/grid-layout.css +7 -3
- package/dist/tide-design-system.js +45 -39
- package/index.ts +122 -0
- package/package.json +8 -12
- package/src/assets/css/animation.css +14 -0
- package/src/assets/css/dynamic-buttons.css +79 -0
- package/src/assets/css/dynamic-utilities.css +39 -0
- package/src/assets/css/grid-layout.css +71 -0
- package/src/assets/css/main.css +5 -0
- package/src/assets/css/realm/aero.css +42 -0
- package/src/assets/css/realm/atv.css +43 -0
- package/src/assets/css/realm/boatmart.css +42 -0
- package/src/assets/css/realm/cycle.css +42 -0
- package/src/assets/css/realm/equip.css +42 -0
- package/src/assets/css/realm/pwc.css +42 -0
- package/src/assets/css/realm/rv.css +50 -0
- package/src/assets/css/realm/snow.css +42 -0
- package/src/assets/css/realm/truck.css +42 -0
- package/src/assets/css/reset.css +79 -0
- package/src/assets/css/storybook.css +9 -0
- package/src/assets/css/utilities.css +1602 -0
- package/src/assets/css/variables.css +118 -0
- package/src/assets/svg/icons/IconAccountBalance.svg +5 -0
- package/src/assets/svg/icons/IconAdd.svg +3 -0
- package/src/assets/svg/icons/IconAiDescription.svg +7 -0
- package/src/assets/svg/icons/IconAlignSpace.svg +3 -0
- package/src/assets/svg/icons/IconApplePay.svg +5 -0
- package/src/assets/svg/icons/IconArrowBack.svg +3 -0
- package/src/assets/svg/icons/IconArrowForward.svg +3 -0
- package/src/assets/svg/icons/IconArrowRight.svg +3 -0
- package/src/assets/svg/icons/IconAssignment.svg +5 -0
- package/src/assets/svg/icons/IconAwardStar.svg +5 -0
- package/src/assets/svg/icons/IconBookmark.svg +5 -0
- package/src/assets/svg/icons/IconCalendarMonth.svg +5 -0
- package/src/assets/svg/icons/IconCall.svg +5 -0
- package/src/assets/svg/icons/IconCheck.svg +3 -0
- package/src/assets/svg/icons/IconChevronLeft.svg +3 -0
- package/src/assets/svg/icons/IconChevronRight.svg +3 -0
- package/src/assets/svg/icons/IconClear.svg +5 -0
- package/src/assets/svg/icons/IconClose.svg +3 -0
- package/src/assets/svg/icons/IconCycle.svg +5 -0
- package/src/assets/svg/icons/IconDelete.svg +5 -0
- package/src/assets/svg/icons/IconDiamond.svg +5 -0
- package/src/assets/svg/icons/IconDraft.svg +3 -0
- package/src/assets/svg/icons/IconEdit.svg +5 -0
- package/src/assets/svg/icons/IconError.svg +5 -0
- package/src/assets/svg/icons/IconExpandContent.svg +3 -0
- package/src/assets/svg/icons/IconExpandLess.svg +3 -0
- package/src/assets/svg/icons/IconExpandMore.svg +3 -0
- package/src/assets/svg/icons/IconFacebook.svg +5 -0
- package/src/assets/svg/icons/IconFavorite.svg +5 -0
- package/src/assets/svg/icons/IconFavoriteFilled.svg +5 -0
- package/src/assets/svg/icons/IconFormatBold.svg +5 -0
- package/src/assets/svg/icons/IconFormatItalic.svg +3 -0
- package/src/assets/svg/icons/IconFormatListBulleted.svg +5 -0
- package/src/assets/svg/icons/IconForum.svg +5 -0
- package/src/assets/svg/icons/IconGavel.svg +5 -0
- package/src/assets/svg/icons/IconGoogle.svg +18 -0
- package/src/assets/svg/icons/IconGooglePay.svg +5 -0
- package/src/assets/svg/icons/IconGrid.svg +3 -0
- package/src/assets/svg/icons/IconHeight.svg +3 -0
- package/src/assets/svg/icons/IconHelp.svg +5 -0
- package/src/assets/svg/icons/IconInfo.svg +5 -0
- package/src/assets/svg/icons/IconInsertText.svg +5 -0
- package/src/assets/svg/icons/IconInstagram.svg +5 -0
- package/src/assets/svg/icons/IconIosShare.svg +5 -0
- package/src/assets/svg/icons/IconLayout.svg +5 -0
- package/src/assets/svg/icons/IconLinkedIn.svg +5 -0
- package/src/assets/svg/icons/IconLocalShipping.svg +5 -0
- package/src/assets/svg/icons/IconLock.svg +5 -0
- package/src/assets/svg/icons/IconMail.svg +5 -0
- package/src/assets/svg/icons/IconMenu.svg +3 -0
- package/src/assets/svg/icons/IconMoreHoriz.svg +5 -0
- package/src/assets/svg/icons/IconNotifications.svg +5 -0
- package/src/assets/svg/icons/IconOpenInNew.svg +5 -0
- package/src/assets/svg/icons/IconPalette.svg +5 -0
- package/src/assets/svg/icons/IconPaypal.svg +5 -0
- package/src/assets/svg/icons/IconPerson.svg +5 -0
- package/src/assets/svg/icons/IconPhotoCamera.svg +5 -0
- package/src/assets/svg/icons/IconPinterest.svg +5 -0
- package/src/assets/svg/icons/IconPlayArrow.svg +3 -0
- package/src/assets/svg/icons/IconRemove.svg +3 -0
- package/src/assets/svg/icons/IconRoundedCorners.svg +5 -0
- package/src/assets/svg/icons/IconRuler.svg +3 -0
- package/src/assets/svg/icons/IconSearch.svg +5 -0
- package/src/assets/svg/icons/IconSeating.svg +3 -0
- package/src/assets/svg/icons/IconSell.svg +5 -0
- package/src/assets/svg/icons/IconShare.svg +5 -0
- package/src/assets/svg/icons/IconShoppingCart.svg +5 -0
- package/src/assets/svg/icons/IconSms.svg +5 -0
- package/src/assets/svg/icons/IconStar.svg +5 -0
- package/src/assets/svg/icons/IconSwapVert.svg +5 -0
- package/src/assets/svg/icons/IconThreeDRotation.svg +18 -0
- package/src/assets/svg/icons/IconTrophy.svg +5 -0
- package/src/assets/svg/icons/IconTune.svg +5 -0
- package/src/assets/svg/icons/IconTwitter.svg +5 -0
- package/src/assets/svg/icons/IconVideocam.svg +5 -0
- package/src/assets/svg/icons/IconViewInAr.svg +5 -0
- package/src/assets/svg/icons/IconVisibility.svg +5 -0
- package/src/assets/svg/icons/IconVolumeOff.svg +5 -0
- package/src/assets/svg/icons/IconVolumeOn.svg +5 -0
- package/src/assets/svg/icons/IconWarning.svg +5 -0
- package/src/assets/svg/icons/IconWeight.svg +3 -0
- package/src/assets/svg/icons/IconWidth.svg +3 -0
- package/src/assets/svg/icons/IconYoutube.svg +5 -0
- package/src/components/TideAccordionItem.vue +105 -0
- package/src/components/TideAlert.vue +124 -0
- package/src/components/TideBackgroundImage.vue +44 -0
- package/src/components/TideBadge.vue +30 -0
- package/src/components/TideBadgePremium.vue +31 -0
- package/src/components/TideBadgeTrustedPartner.vue +38 -0
- package/src/components/TideBreadCrumbs.vue +53 -0
- package/src/components/TideButton.vue +67 -0
- package/src/components/TideButtonIcon.vue +52 -0
- package/src/components/TideButtonPagination.vue +71 -0
- package/src/components/TideCard.vue +19 -0
- package/src/components/TideCarousel.vue +188 -0
- package/src/components/TideChipAction.vue +48 -0
- package/src/components/TideChipFilter.vue +55 -0
- package/src/components/TideChipInput.vue +44 -0
- package/src/components/TideColumns.vue +53 -0
- package/src/components/TideDivider.vue +24 -0
- package/src/components/TideIcon.vue +58 -0
- package/src/components/TideImage.vue +44 -0
- package/src/components/TideIndicator.vue +57 -0
- package/src/components/TideInputCheckbox.vue +145 -0
- package/src/components/TideInputRadio.vue +87 -0
- package/src/components/TideInputSelect.vue +204 -0
- package/src/components/TideInputText.vue +292 -0
- package/src/components/TideInputTextarea.vue +196 -0
- package/src/components/TideLink.vue +66 -0
- package/src/components/TideModal.vue +187 -0
- package/src/components/TidePagination.vue +67 -0
- package/src/components/TideSeoLinks.vue +58 -0
- package/src/components/TideTabs.vue +89 -0
- package/src/components/TideToggle.vue +95 -0
- package/src/docs/development.md +51 -0
- package/src/docs/integration.md +79 -0
- package/src/docs/storybook.md +39 -0
- package/src/stories/DemoCssUtilities.stories.ts +154 -0
- package/src/stories/DemoCssUtilitiesByTextInput.stories.ts +61 -0
- package/src/stories/FoundationsBorder.stories.ts +230 -0
- package/src/stories/FoundationsGap.stories.ts +180 -0
- package/src/stories/FoundationsMargin.stories.ts +155 -0
- package/src/stories/FoundationsPadding.stories.ts +108 -0
- package/src/stories/FoundationsShadow.stories.ts +84 -0
- package/src/stories/FoundationsTypography.stories.ts +172 -0
- package/src/stories/Template.stories.ts +71 -0
- package/src/stories/TideAccordionItem.stories.ts +68 -0
- package/src/stories/TideAlert.stories.ts +58 -0
- package/src/stories/TideBackgroundImage.stories.ts +53 -0
- package/src/stories/TideBadge.stories.ts +31 -0
- package/src/stories/TideBadgePremium.stories.ts +31 -0
- package/src/stories/TideBadgeTrustedPartner.stories.ts +33 -0
- package/src/stories/TideBreadCrumbs.stories.ts +43 -0
- package/src/stories/TideButton.stories.ts +118 -0
- package/src/stories/TideButtonIcon.stories.ts +103 -0
- package/src/stories/TideButtonPagination.stories.ts +99 -0
- package/src/stories/TideCard.stories.ts +38 -0
- package/src/stories/TideCarousel.stories.ts +130 -0
- package/src/stories/TideChipAction.stories.ts +46 -0
- package/src/stories/TideChipFilter.stories.ts +59 -0
- package/src/stories/TideChipInput.stories.ts +42 -0
- package/src/stories/TideColumns.stories.ts +90 -0
- package/src/stories/TideDivider.stories.ts +46 -0
- package/src/stories/TideIcon.stories.ts +29 -0
- package/src/stories/TideIndicator.stories.ts +31 -0
- package/src/stories/TideInputCheckbox.stories.ts +86 -0
- package/src/stories/TideInputRadio.stories.ts +71 -0
- package/src/stories/TideInputSelect.stories.ts +145 -0
- package/src/stories/TideInputText.stories.ts +181 -0
- package/src/stories/TideInputTextarea.stories.ts +116 -0
- package/src/stories/TideLink.stories.ts +137 -0
- package/src/stories/TideModal.stories.ts +122 -0
- package/src/stories/TidePagination.stories.ts +83 -0
- package/src/stories/TideSeoLinks.stories.ts +67 -0
- package/src/stories/TideTabs.stories.ts +100 -0
- package/src/stories/TideToggle.stories.ts +69 -0
- package/src/stories/Welcome.mdx +17 -0
- package/src/types/Alert.ts +8 -0
- package/src/types/Badge.ts +21 -0
- package/src/types/BreadCrumb.ts +5 -0
- package/src/types/Detail.ts +4 -0
- package/src/types/Element.ts +13 -0
- package/src/types/FacetRange.ts +84 -0
- package/src/types/Field.ts +54 -0
- package/src/types/Form.ts +58 -0
- package/src/types/Formatted.ts +22 -0
- package/src/types/Icon.ts +87 -0
- package/src/types/Link.ts +5 -0
- package/src/types/ListingMedia.ts +43 -0
- package/src/types/Orientation.ts +6 -0
- package/src/types/Priority.ts +11 -0
- package/src/types/Raw.ts +5 -0
- package/src/types/Realm.ts +13 -0
- package/src/types/RealmConfig.ts +14 -0
- package/src/types/Select.ts +10 -0
- package/src/types/Size.ts +6 -0
- package/src/types/Storybook.ts +219 -0
- package/src/types/Styles.ts +590 -0
- package/src/types/Tab.ts +5 -0
- package/src/types/Target.ts +6 -0
- package/src/types/TextInput.ts +16 -0
- package/src/types/Validation.ts +24 -0
- package/src/utilities/format.ts +184 -0
- package/src/utilities/storybook.ts +295 -0
- package/src/utilities/validation.ts +197 -0
- package/tests/utilities-format.spec.ts +430 -0
- package/tsconfig.app.json +14 -0
- package/tsconfig.config.json +12 -0
- package/tsconfig.json +22 -0
- package/tsconfig.vitest.json +10 -0
- package/vite.config.ts +43 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/* Snowmobile Trader Realm Colors */
|
|
2
|
+
:root {
|
|
3
|
+
/* Realm-specific Tonal Palette: Only to be referenced in the assignment of Color Roles below. */
|
|
4
|
+
--tide-color1: #193778;
|
|
5
|
+
--tide-color2: #10234C;
|
|
6
|
+
--tide-color3: #4F60A7;
|
|
7
|
+
|
|
8
|
+
--tide-bg-gradient: linear-gradient(
|
|
9
|
+
to bottom right,
|
|
10
|
+
var(--tide-color3) 50%,
|
|
11
|
+
var(--tide-color2) 150%
|
|
12
|
+
);
|
|
13
|
+
|
|
14
|
+
--tide-floating: rgba(255, 255, 255, 0);
|
|
15
|
+
|
|
16
|
+
/* Color Roles: Each realm will assign values to this same series of variables from a combination of the Global and Realm-specific Palettes. */
|
|
17
|
+
--tide-primary: var(--tide-color1);
|
|
18
|
+
--tide-on-primary: var(--tide-white);
|
|
19
|
+
|
|
20
|
+
--tide-secondary: var(--tide-black);
|
|
21
|
+
--tide-on-secondary: var(--tide-white);
|
|
22
|
+
|
|
23
|
+
--tide-surface: var(--tide-white);
|
|
24
|
+
--tide-surface-variant: var(--tide-gray-200);
|
|
25
|
+
--tide-surface-brand: var(--tide-color1);
|
|
26
|
+
--tide-surface-accent: var(--tide-color2);
|
|
27
|
+
--tide-surface-accent-variant: var(--tide-color3);
|
|
28
|
+
--tide-surface-gradient: var(--tide-gradient);
|
|
29
|
+
--tide-surface-floating: var(--tide-floating);
|
|
30
|
+
|
|
31
|
+
--tide-on-surface: var(--tide-black);
|
|
32
|
+
--tide-on-surface-variant: var(--tide-gray-800);
|
|
33
|
+
--tide-on-surface-brand: var(--tide-color1);
|
|
34
|
+
|
|
35
|
+
--tide-on-surface-inverse: var(--tide-white);
|
|
36
|
+
--tide-on-surface-inverse-variant: var(--tide-transparent-200);
|
|
37
|
+
|
|
38
|
+
--tide-border: var(--tide-gray-400);
|
|
39
|
+
--tide-border-low: var(--tide-gray-600);
|
|
40
|
+
--tide-border-high: var(--tide-black);
|
|
41
|
+
--tide-border-floating: var(--tide-gray-300);
|
|
42
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/* Commercial Truck Trader Realm Colors */
|
|
2
|
+
:root {
|
|
3
|
+
/* Realm-specific Tonal Palette: Only to be referenced in the assignment of Color Roles below. */
|
|
4
|
+
--tide-blue: #005F9E;
|
|
5
|
+
--tide-midnight-blue: #172C4B;
|
|
6
|
+
--tide-teal: #97D9E3;
|
|
7
|
+
|
|
8
|
+
--tide-bg-gradient: linear-gradient(
|
|
9
|
+
to bottom right,
|
|
10
|
+
var(--tide-midnight-blue) 50%,
|
|
11
|
+
var(--tide-teal) 150%
|
|
12
|
+
);
|
|
13
|
+
|
|
14
|
+
--tide-floating: rgba(255, 255, 255, 0);
|
|
15
|
+
|
|
16
|
+
/* Color Roles: Each realm will assign values to this same series of variables from a combination of the Global and Realm-specific Palettes. */
|
|
17
|
+
--tide-primary: var(--tide-blue);
|
|
18
|
+
--tide-on-primary: var(--tide-white);
|
|
19
|
+
|
|
20
|
+
--tide-secondary: var(--tide-black);
|
|
21
|
+
--tide-on-secondary: var(--tide-white);
|
|
22
|
+
|
|
23
|
+
--tide-surface: var(--tide-white);
|
|
24
|
+
--tide-surface-variant: var(--tide-gray-200);
|
|
25
|
+
--tide-surface-brand: var(--tide-blue);
|
|
26
|
+
--tide-surface-accent: var(--tide-teal);
|
|
27
|
+
--tide-surface-accent-variant: var(--tide-midnight-blue);
|
|
28
|
+
--tide-surface-gradient: var(--tide-gradient);
|
|
29
|
+
--tide-surface-floating: var(--tide-floating);
|
|
30
|
+
|
|
31
|
+
--tide-on-surface: var(--tide-black);
|
|
32
|
+
--tide-on-surface-variant: var(--tide-gray-800);
|
|
33
|
+
--tide-on-surface-brand: var(--tide-blue);
|
|
34
|
+
|
|
35
|
+
--tide-on-surface-inverse: var(--tide-white);
|
|
36
|
+
--tide-on-surface-inverse-variant: var(--tide-transparent-200);
|
|
37
|
+
|
|
38
|
+
--tide-border: var(--tide-gray-400);
|
|
39
|
+
--tide-border-low: var(--tide-gray-600);
|
|
40
|
+
--tide-border-high: var(--tide-black);
|
|
41
|
+
--tide-border-floating: var(--tide-gray-300);
|
|
42
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
html,
|
|
2
|
+
body {
|
|
3
|
+
color: var(--tide-on-surface);
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
*,
|
|
7
|
+
*::before,
|
|
8
|
+
*::after {
|
|
9
|
+
box-sizing: border-box;
|
|
10
|
+
margin: 0;
|
|
11
|
+
border: 0;
|
|
12
|
+
padding: 0;
|
|
13
|
+
color: inherit;
|
|
14
|
+
font-family: Montserrat;
|
|
15
|
+
font-weight: var(--tide-font-500);
|
|
16
|
+
-webkit-font-smoothing: antialiased;
|
|
17
|
+
-moz-osx-font-smoothing: grayscale;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
h1 {font-size: var(--tide-font-32);} /* 32px */
|
|
21
|
+
h2 {font-size: var(--tide-font-24);} /* 24px */
|
|
22
|
+
h3 {font-size: var(--tide-font-20);} /* 20px */
|
|
23
|
+
h4 {font-size: var(--tide-font-16);} /* 16px */
|
|
24
|
+
h5 {font-size: var(--tide-font-16);} /* 16px */
|
|
25
|
+
|
|
26
|
+
h1,
|
|
27
|
+
h2,
|
|
28
|
+
h3,
|
|
29
|
+
h4,
|
|
30
|
+
h5 {
|
|
31
|
+
font-weight: var(--tide-font-700);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
img,
|
|
35
|
+
label {
|
|
36
|
+
display: block;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
img {
|
|
40
|
+
max-width: 100%;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
p {
|
|
44
|
+
max-width: 80ch;
|
|
45
|
+
line-height: 150%;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
button,
|
|
49
|
+
input,
|
|
50
|
+
option,
|
|
51
|
+
select,
|
|
52
|
+
textarea {
|
|
53
|
+
background-color: unset;
|
|
54
|
+
font-family: inherit;
|
|
55
|
+
font-size: inherit;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
button:enabled,
|
|
59
|
+
select {
|
|
60
|
+
cursor: pointer;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
button:disabled {
|
|
64
|
+
cursor: not-allowed;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/* cross-browser normalization */
|
|
68
|
+
input::placeholder {
|
|
69
|
+
color: var(--tide-gray); /* TODO: replace with an accessible light text color from design system */
|
|
70
|
+
opacity: 1;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/* Clears the ‘X’ from Chrome */
|
|
74
|
+
input::-webkit-search-decoration,
|
|
75
|
+
input::-webkit-search-cancel-button,
|
|
76
|
+
input::-webkit-search-results-button,
|
|
77
|
+
input::-webkit-search-results-decoration {
|
|
78
|
+
display: none;
|
|
79
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/* Styles used for Storybook demonstration purposes only. Not bundled into distribution package. */
|
|
2
|
+
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap');
|
|
3
|
+
|
|
4
|
+
.sb-border-blue-light {border: 1px solid #CCDEF3;}
|
|
5
|
+
|
|
6
|
+
.sb-bg-blue-light {background-color: #CCDEF3;}
|
|
7
|
+
.sb-bg-white {background-color: #FFFFFF;}
|
|
8
|
+
|
|
9
|
+
.sb-font-blue-light {color: #CCDEF3;}
|