@allovoisins/sequoia 0.1.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 (40) hide show
  1. package/README.md +48 -0
  2. package/dist/components/SqButton/SqButton.css +159 -0
  3. package/dist/components/SqButton/SqButton.d.vue.ts +16 -0
  4. package/dist/components/SqButton/SqButton.types.d.ts +110 -0
  5. package/dist/components/SqButton/SqButton.types.d.ts.map +1 -0
  6. package/dist/components/SqButton/SqButton.vue.d.ts +16 -0
  7. package/dist/components/SqButton/SqButton.vue.d.ts.map +1 -0
  8. package/dist/components/SqButton/SqButton.vue_vue_type_script_setup_true_lang.js +111 -0
  9. package/dist/components/SqButton/SqButton.vue_vue_type_script_setup_true_lang.js.map +1 -0
  10. package/dist/components/SqButton/SqButton2.js +7 -0
  11. package/dist/components/SqButton/SqButton2.js.map +1 -0
  12. package/dist/components/SqButton/index.d.ts +3 -0
  13. package/dist/components/SqButton/index.d.ts.map +1 -0
  14. package/dist/components/SqButton/index.js +2 -0
  15. package/dist/index.d.ts +3 -0
  16. package/dist/index.d.ts.map +1 -0
  17. package/dist/index.js +2 -0
  18. package/dist/internal/icons/SqSpinnerIcon.css +16 -0
  19. package/dist/internal/icons/SqSpinnerIcon.d.vue.ts +4 -0
  20. package/dist/internal/icons/SqSpinnerIcon.vue.d.ts +4 -0
  21. package/dist/internal/icons/SqSpinnerIcon.vue.d.ts.map +1 -0
  22. package/dist/internal/icons/SqSpinnerIcon.vue_vue_type_script_setup_true_lang.js +54 -0
  23. package/dist/internal/icons/SqSpinnerIcon.vue_vue_type_script_setup_true_lang.js.map +1 -0
  24. package/dist/internal/icons/SqSpinnerIcon2.js +7 -0
  25. package/dist/internal/icons/SqSpinnerIcon2.js.map +1 -0
  26. package/dist/styles.css +190 -0
  27. package/dist/styles.d.ts +1 -0
  28. package/dist/styles.d.ts.map +1 -0
  29. package/dist/styles.js +2 -0
  30. package/package.json +85 -0
  31. package/src/styles/_custom-properties.scss +157 -0
  32. package/src/styles/abstracts/_colors.scss +500 -0
  33. package/src/styles/abstracts/_functions.scss +37 -0
  34. package/src/styles/abstracts/_index.scss +15 -0
  35. package/src/styles/abstracts/_mixins.scss +103 -0
  36. package/src/styles/abstracts/_variables.scss +147 -0
  37. package/src/styles/base/_fonts.scss +87 -0
  38. package/src/styles/base/_reset.scss +86 -0
  39. package/src/styles/base/_typography.scss +49 -0
  40. package/src/styles/index.scss +22 -0
@@ -0,0 +1,190 @@
1
+ @font-face {
2
+ font-family: "TT Chocolates Fallback";
3
+ src: local("Segoe UI"), local("Arial");
4
+ font-weight: 500;
5
+ font-style: normal;
6
+ ascent-override: 100.293%;
7
+ descent-override: 28.4668%;
8
+ line-gap-override: 0%;
9
+ size-adjust: 100%;
10
+ }
11
+ @font-face {
12
+ font-family: "TT Chocolates Fallback";
13
+ src: local("Segoe UI Italic"), local("Arial Italic"), local("Arial");
14
+ font-weight: 500;
15
+ font-style: italic;
16
+ ascent-override: 100.293%;
17
+ descent-override: 28.4668%;
18
+ line-gap-override: 0%;
19
+ size-adjust: 100%;
20
+ }
21
+ @font-face {
22
+ font-family: "TT Chocolates Fallback";
23
+ src: local("Segoe UI Semibold"), local("Segoe UI"), local("Arial Bold"), local("Arial");
24
+ font-weight: 600;
25
+ font-style: normal;
26
+ ascent-override: 102.002%;
27
+ descent-override: 29.6387%;
28
+ line-gap-override: 0%;
29
+ size-adjust: 100%;
30
+ }
31
+ @font-face {
32
+ font-family: "TT Chocolates Fallback";
33
+ src: local("Segoe UI Bold"), local("Arial Bold"), local("Arial");
34
+ font-weight: 700;
35
+ font-style: normal;
36
+ ascent-override: 103.6133%;
37
+ descent-override: 30.8594%;
38
+ line-gap-override: 0%;
39
+ size-adjust: 100%;
40
+ }
41
+ *,
42
+ *::before,
43
+ *::after {
44
+ box-sizing: border-box;
45
+ }
46
+
47
+ h1,
48
+ h2,
49
+ h3,
50
+ h4,
51
+ h5,
52
+ h6,
53
+ p,
54
+ figure,
55
+ blockquote,
56
+ dl,
57
+ dd {
58
+ margin: 0;
59
+ }
60
+
61
+ ul[role=list],
62
+ ol[role=list] {
63
+ padding: 0;
64
+ margin: 0;
65
+ list-style: none;
66
+ }
67
+
68
+ img,
69
+ picture,
70
+ video,
71
+ canvas,
72
+ svg {
73
+ display: block;
74
+ max-width: 100%;
75
+ }
76
+
77
+ input,
78
+ button,
79
+ textarea,
80
+ select {
81
+ font: inherit;
82
+ color: inherit;
83
+ }
84
+
85
+ p,
86
+ h1,
87
+ h2,
88
+ h3,
89
+ h4,
90
+ h5,
91
+ h6 {
92
+ overflow-wrap: break-word;
93
+ }
94
+
95
+ @media (prefers-reduced-motion: reduce) {
96
+ *,
97
+ *::before,
98
+ *::after {
99
+ animation-duration: 0.01ms !important;
100
+ animation-iteration-count: 1 !important;
101
+ transition-duration: 0.01ms !important;
102
+ scroll-behavior: auto !important;
103
+ }
104
+ }
105
+ html {
106
+ /* stylelint-disable-next-line property-no-vendor-prefix */
107
+ -webkit-text-size-adjust: 100%;
108
+ text-size-adjust: 100%;
109
+ }
110
+
111
+ body {
112
+ font-family: "TT Chocolates", "TT Chocolates Fallback", "Segoe UI", system-ui, sans-serif;
113
+ font-size: 0.875rem;
114
+ font-weight: 500;
115
+ line-height: 1.5;
116
+ color: #172433;
117
+ background-color: #ffffff;
118
+ -webkit-font-smoothing: antialiased;
119
+ -moz-osx-font-smoothing: grayscale;
120
+ }
121
+
122
+ strong,
123
+ b {
124
+ font-weight: 700;
125
+ }
126
+
127
+ em,
128
+ i {
129
+ font-style: italic;
130
+ }
131
+
132
+ :root {
133
+ --sq-font-family-base: "TT Chocolates", "TT Chocolates Fallback", "Segoe UI", system-ui, sans-serif;
134
+ --sq-font-family-mono: "JetBrains Mono", "Courier New", monospace;
135
+ --sq-color-text-primary: #172433;
136
+ --sq-color-text-secondary: #5d728c;
137
+ --sq-color-text-on-dark: #ffffff;
138
+ --sq-color-surface-default: #ffffff;
139
+ --sq-color-surface-sunken: #f2f8ff;
140
+ --sq-color-border-default: #ccd7e5;
141
+ --sq-color-semantic-negative: #ff3b30;
142
+ --sq-color-semantic-critical: #ff9333;
143
+ --sq-color-semantic-positive: #32d74b;
144
+ --sq-color-semantic-information: #007aff;
145
+ --sq-color-focus-ring: #dc164f;
146
+ --sq-font-size-xs: 0.4375rem;
147
+ --sq-font-size-sm: 0.75rem;
148
+ --sq-font-size-base: 0.875rem;
149
+ --sq-font-size-md: 1rem;
150
+ --sq-font-size-lg: 1.125rem;
151
+ --sq-font-size-xl: 1.25rem;
152
+ --sq-font-size-2xl: 1.5rem;
153
+ --sq-font-size-3xl: 2rem;
154
+ --sq-font-weight-regular: 500;
155
+ --sq-font-weight-medium: 500;
156
+ --sq-font-weight-semibold: 600;
157
+ --sq-font-weight-bold: 700;
158
+ --sq-line-height-tight: 1.2;
159
+ --sq-line-height-base: 1.5;
160
+ --sq-line-height-relaxed: 1.75;
161
+ --sq-space-0: 0;
162
+ --sq-space-1: 0.25rem;
163
+ --sq-space-2: 0.5rem;
164
+ --sq-space-3: 0.75rem;
165
+ --sq-space-4: 1rem;
166
+ --sq-space-5: 1.25rem;
167
+ --sq-space-6: 1.5rem;
168
+ --sq-space-8: 2rem;
169
+ --sq-space-10: 2.5rem;
170
+ --sq-space-12: 3rem;
171
+ --sq-space-16: 4rem;
172
+ --sq-space-20: 5rem;
173
+ --sq-space-24: 6rem;
174
+ --sq-radius-sm: 4px;
175
+ --sq-radius-base: 8px;
176
+ --sq-radius-md: 12px;
177
+ --sq-radius-lg: 16px;
178
+ --sq-radius-xl: 24px;
179
+ --sq-radius-full: 9999px;
180
+ --sq-shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.05);
181
+ --sq-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
182
+ --sq-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
183
+ --sq-shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
184
+ --sq-shadow-xl: 0 16px 40px rgba(0, 0, 0, 0.14);
185
+ --sq-duration-fast: 120ms;
186
+ --sq-duration-base: 200ms;
187
+ --sq-duration-slow: 320ms;
188
+ --sq-easing-standard: cubic-bezier(0.2, 0, 0, 1);
189
+ --sq-easing-decelerate: cubic-bezier(0, 0, 0, 1);
190
+ }
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../src/styles.ts"],"names":[],"mappings":"AAEA,OAAO,qBAAqB,CAAC"}
package/dist/styles.js ADDED
@@ -0,0 +1,2 @@
1
+ import './styles.css';
2
+ /* empty css */
package/package.json ADDED
@@ -0,0 +1,85 @@
1
+ {
2
+ "name": "@allovoisins/sequoia",
3
+ "version": "0.1.0-next.0",
4
+ "description": "Design system d'AlloVoisins — composants Vue 3, tokens et styles.",
5
+ "type": "module",
6
+ "license": "UNLICENSED",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "git+https://github.com/ILokYou/AlloVoisins-Front-Sequoia.git",
10
+ "directory": "packages/sequoia"
11
+ },
12
+ "publishConfig": {
13
+ "access": "public"
14
+ },
15
+ "sideEffects": [
16
+ "**/*.css",
17
+ "**/*.scss"
18
+ ],
19
+ "files": [
20
+ "dist",
21
+ "src/styles",
22
+ "README.md"
23
+ ],
24
+ "exports": {
25
+ ".": {
26
+ "types": "./dist/index.d.ts",
27
+ "import": "./dist/index.js"
28
+ },
29
+ "./components/*": {
30
+ "types": "./dist/components/*/index.d.ts",
31
+ "import": "./dist/components/*/index.js"
32
+ },
33
+ "./styles": "./dist/styles.css",
34
+ "./scss": "./src/styles/abstracts/_index.scss",
35
+ "./package.json": "./package.json"
36
+ },
37
+ "scripts": {
38
+ "build": "vite build && node scripts/emit-vue-dts-aliases.js",
39
+ "typecheck": "vue-tsc --noEmit -p tsconfig.json && tsc --noEmit -p tsconfig.node.json",
40
+ "check:packaging": "publint && attw --pack . --profile esm-only --exclude-entrypoints styles scss",
41
+ "check:tarball": "node scripts/check-tarball.js",
42
+ "check:no-runtime-deps": "node scripts/check-no-runtime-deps.js",
43
+ "check:css-imports": "node scripts/check-css-imports.js",
44
+ "check:published-css": "node scripts/check-published-css.js",
45
+ "check:playwright-image": "node scripts/check-playwright-image.js",
46
+ "test": "vitest run",
47
+ "test:watch": "vitest",
48
+ "test:coverage": "vitest run --project jsdom --coverage",
49
+ "test:e2e": "playwright test",
50
+ "test:a11y": "playwright test tests/visual/a11y.spec.ts",
51
+ "test:visual": "playwright test tests/visual/screenshots.spec.ts",
52
+ "test:visual:update": "node scripts/update-visual-baselines.js",
53
+ "test:treeshake": "node scripts/check-treeshake.js",
54
+ "size": "size-limit",
55
+ "storybook": "storybook dev -p 6006",
56
+ "build-storybook": "storybook build",
57
+ "check:storybook-index": "node scripts/check-storybook-index.js"
58
+ },
59
+ "peerDependencies": {
60
+ "vue": "^3.5.0"
61
+ },
62
+ "devDependencies": {
63
+ "@arethetypeswrong/cli": "0.18.5",
64
+ "@axe-core/playwright": "4.13.0",
65
+ "@playwright/test": "1.63.0",
66
+ "@size-limit/preset-small-lib": "13.1.1",
67
+ "@storybook/addon-a11y": "^10.6.0",
68
+ "@storybook/addon-docs": "^10.6.0",
69
+ "@storybook/vue3-vite": "^10.6.0",
70
+ "@vitejs/plugin-vue": "^6.0.0",
71
+ "@vitest/coverage-v8": "5.0.0",
72
+ "@vue/test-utils": "2.5.0",
73
+ "http-server": "14.1.1",
74
+ "jsdom": "30.0.1",
75
+ "publint": "0.3.24",
76
+ "sass-embedded": "1.104.1",
77
+ "size-limit": "13.1.1",
78
+ "storybook": "10.6.0",
79
+ "vite": "8.3.0",
80
+ "vite-plugin-dts": "5.1.0",
81
+ "vitest": "5.0.0",
82
+ "vue": "3.5.42",
83
+ "vue-tsc": "3.3.11"
84
+ }
85
+ }
@@ -0,0 +1,157 @@
1
+ // ============================================================
2
+ // Bloc :root — custom properties `--sq-*`
3
+ // ============================================================
4
+ //
5
+ // Seul fichier du design system qui émet des custom properties. Les valeurs sont
6
+ // générées par boucle à partir des tokens SCSS : aucune n'est recopiée à la main,
7
+ // donc aucune ne peut diverger.
8
+ //
9
+ // ⚠️ Ce fichier n'est PAS inclus dans `abstracts/_index.scss`. Il n'est servi que
10
+ // par l'entrée `@allovoisins/sequoia/styles`, et c'est délibéré :
11
+ //
12
+ // - La SPA importe `/styles` et obtient le bloc `:root`, dont elle a besoin pour
13
+ // thémer au runtime.
14
+ // - Le Nuxt active `features.inlineStyles`, qui inline tout CSS global dans le
15
+ // `<head>` de CHAQUE page, sur le chemin critique du LCP. Il consomme donc
16
+ // `/scss` — 0 octet de CSS — et ne paie ce bloc que s'il le demande.
17
+ //
18
+ // Le document de cadrage présente `_custom-properties.scss` comme faisant partie
19
+ // des fondations sans distinguer les deux entrées. Le §1 donne l'arbitrage au
20
+ // Nuxt sur les Core Web Vitals : la séparation est la seule lecture qui satisfait
21
+ // les deux consommateurs. Voir CONSUMERS.md.
22
+ //
23
+ // La palette complète (138 teintes) n'est délibérément PAS exposée en custom
24
+ // properties : ce serait ~5 ko dans le `<head>` de chaque page pour des valeurs
25
+ // que personne ne surcharge au runtime. Elle reste accessible en SCSS via
26
+ // `palette-color()`.
27
+ //
28
+ // ⚠️ Les noms `--sq-*` sont du CONTRAT PUBLIC. Les consommateurs stylent par
29
+ // dessus et aucun typecheck ne verra un renommage : en renommer un est un
30
+ // changement breaking au sens du lot 6.
31
+
32
+ @use 'sass:meta';
33
+ @use 'abstracts/colors' as c;
34
+ @use 'abstracts/variables' as v;
35
+
36
+ // Les maps ci-dessous ne portent aucune valeur : elles associent un suffixe de
37
+ // custom property au token qui la remplit.
38
+
39
+ $_colors: (
40
+ 'text-primary': c.$color-text-primary,
41
+ 'text-secondary': c.$color-text-secondary,
42
+ 'text-on-dark': c.$color-text-on-dark,
43
+ 'surface-default': c.$color-surface-default,
44
+ 'surface-sunken': c.$color-surface-sunken,
45
+ 'border-default': c.$color-border-default,
46
+ 'semantic-negative': c.$color-semantic-negative,
47
+ 'semantic-critical': c.$color-semantic-critical,
48
+ 'semantic-positive': c.$color-semantic-positive,
49
+ 'semantic-information': c.$color-semantic-information,
50
+ 'focus-ring': c.$color-pink-70,
51
+ );
52
+ $_font-sizes: (
53
+ 'xs': v.$font-size-xs,
54
+ 'sm': v.$font-size-sm,
55
+ 'base': v.$font-size-base,
56
+ 'md': v.$font-size-md,
57
+ 'lg': v.$font-size-lg,
58
+ 'xl': v.$font-size-xl,
59
+ '2xl': v.$font-size-2xl,
60
+ '3xl': v.$font-size-3xl,
61
+ );
62
+ $_font-weights: (
63
+ 'regular': v.$font-weight-regular,
64
+ 'medium': v.$font-weight-medium,
65
+ 'semibold': v.$font-weight-semibold,
66
+ 'bold': v.$font-weight-bold,
67
+ );
68
+ $_line-heights: (
69
+ 'tight': v.$line-height-tight,
70
+ 'base': v.$line-height-base,
71
+ 'relaxed': v.$line-height-relaxed,
72
+ );
73
+ $_spaces: (
74
+ '0': v.$space-0,
75
+ '1': v.$space-1,
76
+ '2': v.$space-2,
77
+ '3': v.$space-3,
78
+ '4': v.$space-4,
79
+ '5': v.$space-5,
80
+ '6': v.$space-6,
81
+ '8': v.$space-8,
82
+ '10': v.$space-10,
83
+ '12': v.$space-12,
84
+ '16': v.$space-16,
85
+ '20': v.$space-20,
86
+ '24': v.$space-24,
87
+ );
88
+ $_radii: (
89
+ 'sm': v.$radius-sm,
90
+ 'base': v.$radius-base,
91
+ 'md': v.$radius-md,
92
+ 'lg': v.$radius-lg,
93
+ 'xl': v.$radius-xl,
94
+ 'full': v.$radius-full,
95
+ );
96
+ $_shadows: (
97
+ 'xs': v.$shadow-xs,
98
+ 'sm': v.$shadow-sm,
99
+ 'md': v.$shadow-md,
100
+ 'lg': v.$shadow-lg,
101
+ 'xl': v.$shadow-xl,
102
+ );
103
+ $_durations: (
104
+ 'fast': v.$duration-fast,
105
+ 'base': v.$duration-base,
106
+ 'slow': v.$duration-slow,
107
+ );
108
+ $_easings: (
109
+ 'standard': v.$easing-standard,
110
+ 'decelerate': v.$easing-decelerate,
111
+ );
112
+
113
+ :root {
114
+ // `meta.inspect()` et non l'interpolation simple : celle-ci retire les
115
+ // guillemets des noms de famille, laissant `font-family: TT Chocolates, …`.
116
+ // C'est valide en CSS, mais un nom non quoté casse dès qu'il commence par un
117
+ // chiffre ou contient un caractère réservé — mieux vaut ne pas dépendre de la
118
+ // forme des noms.
119
+ --sq-font-family-base: #{meta.inspect(v.$font-family-base)};
120
+ --sq-font-family-mono: #{meta.inspect(v.$font-family-mono)};
121
+
122
+ @each $name, $value in $_colors {
123
+ --sq-color-#{$name}: #{$value};
124
+ }
125
+
126
+ @each $name, $value in $_font-sizes {
127
+ --sq-font-size-#{$name}: #{$value};
128
+ }
129
+
130
+ @each $name, $value in $_font-weights {
131
+ --sq-font-weight-#{$name}: #{$value};
132
+ }
133
+
134
+ @each $name, $value in $_line-heights {
135
+ --sq-line-height-#{$name}: #{$value};
136
+ }
137
+
138
+ @each $name, $value in $_spaces {
139
+ --sq-space-#{$name}: #{$value};
140
+ }
141
+
142
+ @each $name, $value in $_radii {
143
+ --sq-radius-#{$name}: #{$value};
144
+ }
145
+
146
+ @each $name, $value in $_shadows {
147
+ --sq-shadow-#{$name}: #{$value};
148
+ }
149
+
150
+ @each $name, $value in $_durations {
151
+ --sq-duration-#{$name}: #{$value};
152
+ }
153
+
154
+ @each $name, $value in $_easings {
155
+ --sq-easing-#{$name}: #{$value};
156
+ }
157
+ }