@carissa-io/theme-default 0.3.6 → 0.3.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@carissa-io/theme-default",
3
- "version": "0.3.6",
3
+ "version": "0.3.7",
4
4
  "description": "Carissa UI: the default theme (Swiss minimalism) as SCSS variable overrides of the Carissa components, with a compiled CSS build",
5
5
  "type": "module",
6
6
  "style": "dist/index.css",
@@ -66,7 +66,16 @@
66
66
  "@carissa-io/components-skeleton": "^0.1.0",
67
67
  "@carissa-io/components-progress": "^0.1.0",
68
68
  "@carissa-io/components-tooltip": "^0.1.0",
69
- "@carissa-io/components-prose": "^0.1.0"
69
+ "@carissa-io/components-prose": "^0.1.0",
70
+ "@carissa-io/components-tabs": "^0.1.0",
71
+ "@carissa-io/components-accordion": "^0.1.0",
72
+ "@carissa-io/components-breadcrumb": "^0.1.0",
73
+ "@carissa-io/components-pagination": "^0.1.0",
74
+ "@carissa-io/components-stepper": "^0.1.0",
75
+ "@carissa-io/components-sidebar": "^0.1.0",
76
+ "@carissa-io/components-navbar": "^0.1.0",
77
+ "@carissa-io/components-drawer": "^0.1.0",
78
+ "@carissa-io/components-menu": "^0.1.0"
70
79
  },
71
80
  "peerDependenciesMeta": {
72
81
  "@carissa-io/components-input": {
@@ -167,12 +176,41 @@
167
176
  },
168
177
  "@carissa-io/components-prose": {
169
178
  "optional": true
179
+ },
180
+ "@carissa-io/components-tabs": {
181
+ "optional": true
182
+ },
183
+ "@carissa-io/components-accordion": {
184
+ "optional": true
185
+ },
186
+ "@carissa-io/components-breadcrumb": {
187
+ "optional": true
188
+ },
189
+ "@carissa-io/components-pagination": {
190
+ "optional": true
191
+ },
192
+ "@carissa-io/components-stepper": {
193
+ "optional": true
194
+ },
195
+ "@carissa-io/components-sidebar": {
196
+ "optional": true
197
+ },
198
+ "@carissa-io/components-navbar": {
199
+ "optional": true
200
+ },
201
+ "@carissa-io/components-drawer": {
202
+ "optional": true
203
+ },
204
+ "@carissa-io/components-menu": {
205
+ "optional": true
170
206
  }
171
207
  },
172
208
  "devDependencies": {
209
+ "@carissa-io/components-accordion": "^0.1.0",
173
210
  "@carissa-io/components-alert": "^0.1.0",
174
211
  "@carissa-io/components-avatar": "^0.1.0",
175
212
  "@carissa-io/components-badge": "^0.1.0",
213
+ "@carissa-io/components-breadcrumb": "^0.1.0",
176
214
  "@carissa-io/components-button": "^0.1.1",
177
215
  "@carissa-io/components-calendar": "^0.1.1",
178
216
  "@carissa-io/components-card": "^0.1.0",
@@ -180,20 +218,27 @@
180
218
  "@carissa-io/components-combobox": "^0.1.1",
181
219
  "@carissa-io/components-date-picker": "^0.1.1",
182
220
  "@carissa-io/components-divider": "^0.1.0",
221
+ "@carissa-io/components-drawer": "^0.1.0",
183
222
  "@carissa-io/components-input": "^0.2.1",
184
223
  "@carissa-io/components-link": "^0.1.0",
185
224
  "@carissa-io/components-listbox": "^0.1.1",
225
+ "@carissa-io/components-menu": "^0.1.0",
186
226
  "@carissa-io/components-modal": "^0.1.0",
227
+ "@carissa-io/components-navbar": "^0.1.0",
228
+ "@carissa-io/components-pagination": "^0.1.0",
187
229
  "@carissa-io/components-popover": "^0.1.1",
188
230
  "@carissa-io/components-progress": "^0.1.0",
189
231
  "@carissa-io/components-prose": "^0.1.0",
190
232
  "@carissa-io/components-radio-group": "^0.1.1",
191
233
  "@carissa-io/components-search": "^0.1.1",
192
234
  "@carissa-io/components-select": "^0.1.1",
235
+ "@carissa-io/components-sidebar": "^0.1.0",
193
236
  "@carissa-io/components-skeleton": "^0.1.0",
194
237
  "@carissa-io/components-slider": "^0.1.1",
195
238
  "@carissa-io/components-spinner": "^0.1.0",
239
+ "@carissa-io/components-stepper": "^0.1.0",
196
240
  "@carissa-io/components-switch": "^0.1.1",
241
+ "@carissa-io/components-tabs": "^0.1.0",
197
242
  "@carissa-io/components-tag": "^0.1.0",
198
243
  "@carissa-io/components-toast": "^0.1.0",
199
244
  "@carissa-io/components-tooltip": "^0.1.0",
package/scss/index.scss CHANGED
@@ -937,3 +937,243 @@
937
937
  $c-prose-table-head-background: $var-surface,
938
938
  $c-prose-table-head-font-weight: $font-weight-bold
939
939
  );
940
+
941
+ // Tabs: a --c-muted underline under the list and a 2px --c-primary indicator under the selected tab. Tabs read --c-muted
942
+ // (4.7:1 on the background, 7.9:1 in dark), turn --c-text on a --c-surface hover and the selected one is --c-text and bold.
943
+ // Square, bold, the theme's 1px focus ring inside the tab. No other block forwards it.
944
+ @use '@carissa-io/components-tabs/scss' as tabs with (
945
+ $c-tabs-list-border-width: 1px,
946
+ $c-tabs-list-border-color: $var-muted,
947
+ $c-tabs-tab-padding-x: 1.25rem,
948
+ $c-tabs-tab-padding-y: 0.625rem,
949
+ $c-tabs-tab-font-size: $font-size-small,
950
+ $c-tabs-tab-font-weight: $font-weight-bold,
951
+ $c-tabs-tab-radius: $radius,
952
+ $c-tabs-tab-color: $var-muted,
953
+ $c-tabs-tab-color-hover: $var-text,
954
+ $c-tabs-tab-background-hover: $var-surface,
955
+ $c-tabs-tab-color-selected: $var-text,
956
+ $c-tabs-tab-background-selected: transparent,
957
+ $c-tabs-indicator-width: 2px,
958
+ $c-tabs-indicator-color: $var-primary,
959
+ $c-tabs-focus-outline: $focus-width solid $var-focus,
960
+ $c-tabs-focus-outline-offset: -2px,
961
+ $c-tabs-panel-padding-y: 1.25rem,
962
+ $c-tabs-transition-duration: $transition-duration
963
+ );
964
+
965
+ // Accordion: the box and the rules between items are --c-muted (the card and field edge), headers are bold --c-text with a
966
+ // --c-surface hover, and the chevron follows the header text. Square, the theme's 1px focus ring inside the header.
967
+ @use '@carissa-io/components-accordion/scss' as accordion with (
968
+ $c-accordion-border-width: 1px,
969
+ $c-accordion-border-color: $var-muted,
970
+ $c-accordion-radius: $radius,
971
+ $c-accordion-header-padding-x: 1.25rem,
972
+ $c-accordion-header-padding-y: 0.875rem,
973
+ $c-accordion-header-font-size: $font-size-body,
974
+ $c-accordion-header-font-weight: $font-weight-bold,
975
+ $c-accordion-header-color: $var-text,
976
+ $c-accordion-header-background: transparent,
977
+ $c-accordion-header-background-hover: $var-surface,
978
+ $c-accordion-header-color-open: $var-text,
979
+ $c-accordion-header-background-open: transparent,
980
+ $c-accordion-chevron-color: currentColor,
981
+ $c-accordion-content-padding-x: 1.25rem,
982
+ $c-accordion-content-padding-y: 1rem,
983
+ $c-accordion-focus-outline: $focus-width solid $var-focus,
984
+ $c-accordion-focus-outline-offset: -2px,
985
+ $c-accordion-transition-duration: $transition-duration
986
+ );
987
+
988
+ // Breadcrumb: links and separators in --c-muted (4.7:1 on the background), the current page in --c-text and bold. Links turn
989
+ // --c-text and underline on hover. The theme's 1px focus ring, offset 2px.
990
+ @use '@carissa-io/components-breadcrumb/scss' as breadcrumb with (
991
+ $c-breadcrumb-font-size: $font-size-small,
992
+ $c-breadcrumb-link-color: $var-muted,
993
+ $c-breadcrumb-link-color-hover: $var-text,
994
+ $c-breadcrumb-link-decoration: none,
995
+ $c-breadcrumb-link-decoration-hover: underline,
996
+ $c-breadcrumb-current-color: $var-text,
997
+ $c-breadcrumb-current-font-weight: $font-weight-bold,
998
+ $c-breadcrumb-separator-color: $var-muted,
999
+ $c-breadcrumb-focus-outline: $focus-width solid $var-focus,
1000
+ $c-breadcrumb-focus-outline-offset: 2px,
1001
+ $c-breadcrumb-focus-radius: $radius
1002
+ );
1003
+
1004
+ // Pagination: neutral controls like the secondary button (--c-background with a --c-muted border, --c-surface-active on hover,
1005
+ // 44px touch target), the current page filled --c-primary with --c-on-primary (21:1). Square, bold, the ellipsis in --c-muted.
1006
+ // The theme's 1px focus ring, offset 2px.
1007
+ @use '@carissa-io/components-pagination/scss' as pagination with (
1008
+ $c-pagination-gap: 0.25rem,
1009
+ $c-pagination-font-size: $font-size-small,
1010
+ $c-pagination-control-size: $min-height,
1011
+ $c-pagination-control-padding-x: 0.75rem,
1012
+ $c-pagination-control-radius: $radius,
1013
+ $c-pagination-control-color: $var-text,
1014
+ $c-pagination-control-background: $var-background,
1015
+ $c-pagination-control-border-width: 1px,
1016
+ $c-pagination-control-border-color: $var-muted,
1017
+ $c-pagination-control-color-hover: $var-primary,
1018
+ $c-pagination-control-background-hover: $var-surface-active,
1019
+ $c-pagination-current-color: $var-on-primary,
1020
+ $c-pagination-current-background: $var-primary,
1021
+ $c-pagination-current-border-color: $var-primary,
1022
+ $c-pagination-ellipsis-color: $var-muted,
1023
+ $c-pagination-focus-outline: $focus-width solid $var-focus,
1024
+ $c-pagination-focus-outline-offset: 2px,
1025
+ $c-pagination-transition-duration: $transition-duration
1026
+ );
1027
+
1028
+ // Stepper: a done step is a filled --c-primary marker with --c-on-primary (the check), the current one an outlined
1029
+ // --c-primary marker on the background, an upcoming one a --c-surface-active marker with --c-text (14:1). An error step is a
1030
+ // --c-error marker with --c-on-primary (4.5:1 in light, 7.6:1 in dark) and a --c-error title. Upcoming titles and descriptions
1031
+ // are --c-muted. Connectors are --c-muted lines, --c-primary once the step is done. The theme's 1px focus ring, offset 2px.
1032
+ @use '@carissa-io/components-stepper/scss' as stepper with (
1033
+ $c-stepper-font-size: $font-size-small,
1034
+ $c-stepper-marker-size: 2rem,
1035
+ $c-stepper-marker-font-size: $font-size-small,
1036
+ $c-stepper-marker-border-width: 2px,
1037
+ $c-stepper-marker-color: $var-text,
1038
+ $c-stepper-marker-background: $var-surface-active,
1039
+ $c-stepper-marker-border-color: $var-surface-active,
1040
+ $c-stepper-marker-current-color: $var-text,
1041
+ $c-stepper-marker-current-background: $var-background,
1042
+ $c-stepper-marker-current-border-color: $var-primary,
1043
+ $c-stepper-marker-complete-color: $var-on-primary,
1044
+ $c-stepper-marker-complete-background: $var-primary,
1045
+ $c-stepper-marker-complete-border-color: $var-primary,
1046
+ $c-stepper-marker-error-color: $var-on-primary,
1047
+ $c-stepper-marker-error-background: $var-error,
1048
+ $c-stepper-marker-error-border-color: $var-error,
1049
+ $c-stepper-title-font-weight: $font-weight-bold,
1050
+ $c-stepper-title-color: $var-text,
1051
+ $c-stepper-title-color-upcoming: $var-muted,
1052
+ $c-stepper-title-color-error: $var-error,
1053
+ $c-stepper-description-color: $var-muted,
1054
+ $c-stepper-connector-width: 2px,
1055
+ $c-stepper-connector-color: $var-muted,
1056
+ $c-stepper-connector-color-complete: $var-primary,
1057
+ $c-stepper-control-radius: $radius,
1058
+ $c-stepper-focus-outline: $focus-width solid $var-focus,
1059
+ $c-stepper-focus-outline-offset: 2px,
1060
+ $c-stepper-transition-duration: $transition-duration
1061
+ );
1062
+
1063
+ // Sidebar: a --c-surface column with a 1px --c-muted edge. Items are --c-text (16.4:1 on the surface) with a --c-surface-active
1064
+ // hover (14.2:1); the current page is filled --c-primary with --c-on-primary (21:1), a shape and not only a hue. Section titles
1065
+ // are the small uppercase label style in --c-text, because --c-muted on --c-surface is only 4.35:1 in light. Square, the
1066
+ // theme's 1px focus ring inside the item. No other block forwards it.
1067
+ @use '@carissa-io/components-sidebar/scss' as sidebar with (
1068
+ $c-sidebar-width: 16rem,
1069
+ $c-sidebar-width-collapsed: 4.5rem,
1070
+ $c-sidebar-padding: 0.75rem,
1071
+ $c-sidebar-gap: 1.5rem,
1072
+ $c-sidebar-background: $var-surface,
1073
+ $c-sidebar-color: $var-text,
1074
+ $c-sidebar-border-width: 1px,
1075
+ $c-sidebar-border-color: $var-muted,
1076
+ $c-sidebar-section-title-color: $var-text,
1077
+ $c-sidebar-section-title-font-size: $label-font-size,
1078
+ $c-sidebar-section-title-font-weight: $label-font-weight,
1079
+ $c-sidebar-section-title-letter-spacing: $label-letter-spacing,
1080
+ $c-sidebar-section-title-transform: uppercase,
1081
+ $c-sidebar-item-gap: 0.75rem,
1082
+ $c-sidebar-item-padding-x: 0.75rem,
1083
+ $c-sidebar-item-padding-y: 0.625rem,
1084
+ $c-sidebar-item-font-size: $font-size-small,
1085
+ $c-sidebar-item-font-weight: $font-weight-bold,
1086
+ $c-sidebar-item-radius: $radius,
1087
+ $c-sidebar-item-color: $var-text,
1088
+ $c-sidebar-item-color-hover: $var-text,
1089
+ $c-sidebar-item-background-hover: $var-surface-active,
1090
+ $c-sidebar-item-color-active: $var-on-primary,
1091
+ $c-sidebar-item-background-active: $var-primary,
1092
+ $c-sidebar-toggle-size: $min-height,
1093
+ $c-sidebar-toggle-radius: $radius,
1094
+ $c-sidebar-toggle-color: $var-text,
1095
+ $c-sidebar-toggle-background-hover: $var-surface-active,
1096
+ $c-sidebar-focus-outline: $focus-width solid $var-focus,
1097
+ $c-sidebar-focus-outline-offset: -2px,
1098
+ $c-sidebar-transition-duration: $transition-duration
1099
+ );
1100
+
1101
+ // Navbar: a --c-background bar with a 1px --c-muted bottom edge. Items read like the tabs: bold --c-muted (4.7:1 on the
1102
+ // background), --c-text on a --c-surface hover, and --c-text for the current page. The breakpoint is the Sass default (48rem).
1103
+ // Square, 44px toggle, the theme's 1px focus ring inside the item. No other block forwards it.
1104
+ @use '@carissa-io/components-navbar/scss' as navbar with (
1105
+ $c-navbar-padding-x: 1.25rem,
1106
+ $c-navbar-padding-y: 0.5rem,
1107
+ $c-navbar-gap: 1.5rem,
1108
+ $c-navbar-background: $var-background,
1109
+ $c-navbar-color: $var-text,
1110
+ $c-navbar-border-width: 1px,
1111
+ $c-navbar-border-color: $var-muted,
1112
+ $c-navbar-brand-font-size: $font-size-body,
1113
+ $c-navbar-brand-font-weight: $font-weight-bold,
1114
+ $c-navbar-brand-color: $var-text,
1115
+ $c-navbar-item-padding-x: 0.75rem,
1116
+ $c-navbar-item-padding-y: 0.625rem,
1117
+ $c-navbar-item-font-size: $font-size-small,
1118
+ $c-navbar-item-font-weight: $font-weight-bold,
1119
+ $c-navbar-item-radius: $radius,
1120
+ $c-navbar-item-color: $var-muted,
1121
+ $c-navbar-item-color-hover: $var-text,
1122
+ $c-navbar-item-background-hover: $var-surface,
1123
+ $c-navbar-item-color-active: $var-text,
1124
+ $c-navbar-item-background-active: transparent,
1125
+ $c-navbar-toggle-size: $min-height,
1126
+ $c-navbar-toggle-radius: $radius,
1127
+ $c-navbar-toggle-color: $var-text,
1128
+ $c-navbar-toggle-background-hover: $var-surface-active,
1129
+ $c-navbar-focus-outline: $focus-width solid $var-focus,
1130
+ $c-navbar-focus-outline-offset: -2px
1131
+ );
1132
+
1133
+ // Drawer: the Modal's box as a panel on the edge: --c-background with --c-text, a 1px --c-muted border (the edge that still
1134
+ // reads in dark), the same padding and the same close button. The backdrop is the one literal color, black at 50% in both
1135
+ // modes, and so is the shadow. Its index forwards the typography styles, already loaded and configured above: this block
1136
+ // goes after the Typography one.
1137
+ @use '@carissa-io/components-drawer/scss' as drawer with (
1138
+ $c-drawer-background: $var-background,
1139
+ $c-drawer-color: $var-text,
1140
+ $c-drawer-border-width: 1px,
1141
+ $c-drawer-border-color: $var-muted,
1142
+ $c-drawer-radius: $radius,
1143
+ $c-drawer-shadow: (0 4px 8px rgb(0 0 0 / 0.08), 0 16px 48px rgb(0 0 0 / 0.2)),
1144
+ $c-drawer-padding-x: 1.5rem,
1145
+ $c-drawer-padding-y: 1.25rem,
1146
+ $c-drawer-gap: 1rem,
1147
+ $c-drawer-size-sm: 20rem,
1148
+ $c-drawer-size-md: 28rem,
1149
+ $c-drawer-size-lg: 40rem,
1150
+ $c-drawer-close-size: 1.25rem,
1151
+ $c-drawer-close-color: $var-muted,
1152
+ $c-drawer-close-color-hover: $var-text,
1153
+ $c-drawer-backdrop-color: rgb(0 0 0 / 0.5),
1154
+ $c-drawer-transition-duration: $transition-duration
1155
+ );
1156
+
1157
+ // Menu: the panel is the Popover's (--c-background, 1px --c-muted border, flat). Items are --c-text with a --c-surface-active
1158
+ // hover and keyboard focus (14.2:1) and the theme's 1px focus ring; labels are small --c-muted text (4.7:1 on the panel) and
1159
+ // the separator a 1px --c-muted line. Square. Its index forwards the popover styles, already loaded and configured above:
1160
+ // this block goes after the Popover one.
1161
+ @use '@carissa-io/components-menu/scss' as menu with (
1162
+ $c-menu-min-width: 12rem,
1163
+ $c-menu-padding: 0.25rem,
1164
+ $c-menu-radius: $radius,
1165
+ $c-menu-item-padding-x: 0.75rem,
1166
+ $c-menu-item-padding-y: 0.625rem,
1167
+ $c-menu-item-gap: 0.75rem,
1168
+ $c-menu-item-color: $var-text,
1169
+ $c-menu-item-background: transparent,
1170
+ $c-menu-item-color-hover: $var-text,
1171
+ $c-menu-item-background-hover: $var-surface-active,
1172
+ $c-menu-item-focus-outline: $focus-width solid $var-focus,
1173
+ $c-menu-label-color: $var-muted,
1174
+ $c-menu-label-font-size: $font-size-small,
1175
+ $c-menu-label-padding-x: 0.75rem,
1176
+ $c-menu-label-padding-y: 0.5rem,
1177
+ $c-menu-separator-color: $var-muted,
1178
+ $c-menu-separator-margin: 0.25rem
1179
+ );