@tamagui/config 3.0.0-beta.753.1 → 3.0.0-beta.765.1
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/dist/cjs/v6-base.cjs +28 -1
- package/dist/cjs/v6-base.native.cjs +29 -1
- package/dist/cjs/v6-base.native.js +29 -1
- package/dist/cjs/v6-base.native.js.map +1 -1
- package/dist/esm/v6-base.mjs +28 -1
- package/dist/esm/v6-base.mjs.map +1 -1
- package/dist/esm/v6-base.native.js +29 -1
- package/dist/esm/v6-base.native.js.map +1 -1
- package/package.json +12 -12
- package/src/v6-base.ts +78 -3
- package/types/v6-base.d.ts +35 -4
- package/types/v6-base.d.ts.map +1 -1
- package/types/v6.d.ts +130 -1
- package/types/v6.d.ts.map +1 -1
package/dist/cjs/v6-base.cjs
CHANGED
|
@@ -84,6 +84,33 @@ const fonts = {
|
|
|
84
84
|
heading: withTailwindTypeScale(import_fonts.fonts.heading)
|
|
85
85
|
};
|
|
86
86
|
const settings = { ...import_settings.settings };
|
|
87
|
+
function themesWithColorScales(themes, scales) {
|
|
88
|
+
const light = {};
|
|
89
|
+
const dark = {};
|
|
90
|
+
for (const name in scales) {
|
|
91
|
+
const scale = scales[name];
|
|
92
|
+
if (scale.light.length !== 12 || scale.dark.length !== 12) {
|
|
93
|
+
throw new Error(`color scale "${name}" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);
|
|
94
|
+
}
|
|
95
|
+
scale.light.forEach((value, index) => {
|
|
96
|
+
light[`${name}${index + 1}`] = value;
|
|
97
|
+
});
|
|
98
|
+
scale.dark.forEach((value, index) => {
|
|
99
|
+
dark[`${name}${index + 1}`] = value;
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
return {
|
|
103
|
+
...themes,
|
|
104
|
+
light: {
|
|
105
|
+
...themes.light,
|
|
106
|
+
...light
|
|
107
|
+
},
|
|
108
|
+
dark: {
|
|
109
|
+
...themes.dark,
|
|
110
|
+
...dark
|
|
111
|
+
}
|
|
112
|
+
};
|
|
113
|
+
}
|
|
87
114
|
const alignedConfig = {
|
|
88
115
|
media: import_media.media,
|
|
89
116
|
shorthands: import_v6.shorthands,
|
|
@@ -94,7 +121,7 @@ const alignedConfig = {
|
|
|
94
121
|
function createV6Config(colors) {
|
|
95
122
|
return {
|
|
96
123
|
...alignedConfig,
|
|
97
|
-
themes: colors.themes,
|
|
124
|
+
themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,
|
|
98
125
|
tokens: colors.colorTokens ? {
|
|
99
126
|
...tokens,
|
|
100
127
|
color: colors.colorTokens
|
|
@@ -86,6 +86,34 @@ var fonts = {
|
|
|
86
86
|
heading: withTailwindTypeScale(import_fonts.fonts.heading)
|
|
87
87
|
};
|
|
88
88
|
var settings = { ...import_settings.settings };
|
|
89
|
+
function themesWithColorScales(themes, scales) {
|
|
90
|
+
var _loop = function(name2) {
|
|
91
|
+
var scale = scales[name2];
|
|
92
|
+
if (scale.light.length !== 12 || scale.dark.length !== 12) {
|
|
93
|
+
throw new Error(`color scale "${name2}" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);
|
|
94
|
+
}
|
|
95
|
+
scale.light.forEach(function(value, index) {
|
|
96
|
+
light[`${name2}${index + 1}`] = value;
|
|
97
|
+
});
|
|
98
|
+
scale.dark.forEach(function(value, index) {
|
|
99
|
+
dark[`${name2}${index + 1}`] = value;
|
|
100
|
+
});
|
|
101
|
+
};
|
|
102
|
+
var light = {};
|
|
103
|
+
var dark = {};
|
|
104
|
+
for (var name in scales) _loop(name);
|
|
105
|
+
return {
|
|
106
|
+
...themes,
|
|
107
|
+
light: {
|
|
108
|
+
...themes.light,
|
|
109
|
+
...light
|
|
110
|
+
},
|
|
111
|
+
dark: {
|
|
112
|
+
...themes.dark,
|
|
113
|
+
...dark
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
}
|
|
89
117
|
var alignedConfig = {
|
|
90
118
|
media: import_media.media,
|
|
91
119
|
shorthands: import_v6.shorthands,
|
|
@@ -96,7 +124,7 @@ var alignedConfig = {
|
|
|
96
124
|
function createV6Config(colors) {
|
|
97
125
|
return {
|
|
98
126
|
...alignedConfig,
|
|
99
|
-
themes: colors.themes,
|
|
127
|
+
themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,
|
|
100
128
|
tokens: colors.colorTokens ? {
|
|
101
129
|
...tokens,
|
|
102
130
|
color: colors.colorTokens
|
|
@@ -86,6 +86,34 @@ var fonts = {
|
|
|
86
86
|
heading: withTailwindTypeScale(import_fonts.fonts.heading)
|
|
87
87
|
};
|
|
88
88
|
var settings = { ...import_settings.settings };
|
|
89
|
+
function themesWithColorScales(themes, scales) {
|
|
90
|
+
var _loop = function(name2) {
|
|
91
|
+
var scale = scales[name2];
|
|
92
|
+
if (scale.light.length !== 12 || scale.dark.length !== 12) {
|
|
93
|
+
throw new Error(`color scale "${name2}" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);
|
|
94
|
+
}
|
|
95
|
+
scale.light.forEach(function(value, index) {
|
|
96
|
+
light[`${name2}${index + 1}`] = value;
|
|
97
|
+
});
|
|
98
|
+
scale.dark.forEach(function(value, index) {
|
|
99
|
+
dark[`${name2}${index + 1}`] = value;
|
|
100
|
+
});
|
|
101
|
+
};
|
|
102
|
+
var light = {};
|
|
103
|
+
var dark = {};
|
|
104
|
+
for (var name in scales) _loop(name);
|
|
105
|
+
return {
|
|
106
|
+
...themes,
|
|
107
|
+
light: {
|
|
108
|
+
...themes.light,
|
|
109
|
+
...light
|
|
110
|
+
},
|
|
111
|
+
dark: {
|
|
112
|
+
...themes.dark,
|
|
113
|
+
...dark
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
}
|
|
89
117
|
var alignedConfig = {
|
|
90
118
|
media: import_media.media,
|
|
91
119
|
shorthands: import_v6.shorthands,
|
|
@@ -96,7 +124,7 @@ var alignedConfig = {
|
|
|
96
124
|
function createV6Config(colors) {
|
|
97
125
|
return {
|
|
98
126
|
...alignedConfig,
|
|
99
|
-
themes: colors.themes,
|
|
127
|
+
themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,
|
|
100
128
|
tokens: colors.colorTokens ? {
|
|
101
129
|
...tokens,
|
|
102
130
|
color: colors.colorTokens
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v6-base.native.js","names":[],"sources":["cjs/v6-base.native.js"],"sourcesContent":["\"use strict\";\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar v6_base_exports = {};\n__export(v6_base_exports, {\n breakpoints: () => import_media2.breakpoints,\n createSystemFont: () => import_fonts2.createSystemFont,\n createV6Config: () => createV6Config,\n fonts: () => fonts,\n media: () => import_media2.media,\n mediaQueryDefaultActive: () => import_media2.mediaQueryDefaultActive,\n selectionStyles: () => import_settings.selectionStyles,\n settings: () => settings,\n shorthands: () => import_v6.shorthands,\n tailwindSource: () => import_v6_tailwind_scales2.tailwindSource,\n toV6Themes: () => import_v6_themes.toV6Themes,\n tokens: () => tokens,\n v6RemovedThemeNames: () => import_tooling.v6RemovedThemeNames,\n v6ThemeNameReplacements: () => import_tooling.v6ThemeNameReplacements\n});\nmodule.exports = __toCommonJS(v6_base_exports);\nvar import_v6 = require(\"@tamagui/shorthands/v6\");\nvar import_fonts = require(\"./fonts\");\nvar import_media = require(\"./media\");\nvar import_settings = require(\"./settings\");\nvar import_v6_tailwind_scales = require(\"./v6-tailwind-scales.generated\");\nvar import_fonts2 = require(\"./fonts\");\nvar import_media2 = require(\"./media\");\nvar import_v6_tailwind_scales2 = require(\"./v6-tailwind-scales.generated\");\nvar import_tooling = require(\"@tamagui/style-grammar/tooling\");\nvar import_v6_themes = require(\"./v6-themes\");\nvar tokens = {\n space: import_v6_tailwind_scales.tailwindSpace,\n size: import_v6_tailwind_scales.tailwindSize,\n radius: {\n 0: 0,\n 1: 3,\n 2: 5,\n 3: 7,\n 4: 9,\n 5: 10,\n 6: 16,\n 7: 19,\n 8: 22,\n 9: 26,\n 10: 34,\n 11: 42,\n 12: 50,\n ...import_v6_tailwind_scales.tailwindRadius\n }\n};\nfunction withTailwindTypeScale(font) {\n return {\n ...font,\n size: {\n ...font.size,\n ...import_v6_tailwind_scales.tailwindFontSize\n },\n lineHeight: {\n ...font.lineHeight,\n ...import_v6_tailwind_scales.tailwindLineHeight\n }\n };\n}\nvar fonts = {\n body: withTailwindTypeScale(import_fonts.fonts.body),\n heading: withTailwindTypeScale(import_fonts.fonts.heading)\n};\nvar settings = {\n ...import_settings.settings\n};\nvar alignedConfig = {\n media: import_media.media,\n shorthands: import_v6.shorthands,\n fonts,\n selectionStyles: import_settings.selectionStyles,\n settings\n};\nfunction createV6Config(colors) {\n return {\n ...alignedConfig,\n themes: colors.themes,\n tokens: colors.colorTokens ? {\n ...tokens,\n color: colors.colorTokens\n } : tokens\n };\n}\n//# sourceMappingURL=v6-base.js.map\n"],"mappings":";;;AACA,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC9B,KAAK,IAAI,QAAQ,KACf,UAAU,QAAQ,MAAM;EAAE,KAAK,IAAI;EAAO,YAAY;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EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,IAAI;EACJ,IAAI;EACJ,IAAI;EACJ,GAAG,0BAA0B;CAC/B;AACF;AACA,SAAS,sBAAsB,MAAM;CACnC,OAAO;EACL,GAAG;EACH,MAAM;GACJ,GAAG,KAAK;GACR,GAAG,0BAA0B;EAC/B;EACA,YAAY;GACV,GAAG,KAAK;GACR,GAAG,0BAA0B;EAC/B;CACF;AACF;AACA,IAAI,QAAQ;CACV,MAAM,sBAAsB,aAAa,MAAM,IAAI;CACnD,SAAS,sBAAsB,aAAa,MAAM,OAAO;AAC3D;AACA,IAAI,WAAW,EACb,GAAG,gBAAgB,SACrB;AACA,IAAI,gBAAgB;CAClB,OAAO,aAAa;CACpB,YAAY,UAAU;CACtB;CACA,iBAAiB,gBAAgB;CACjC;AACF;AACA,SAAS,eAAe,QAAQ;CAC9B,OAAO;EACL,GAAG;EACH,QAAQ,OAAO;
|
|
1
|
+
{"version":3,"file":"v6-base.native.js","names":[],"sources":["cjs/v6-base.native.js"],"sourcesContent":["\"use strict\";\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar v6_base_exports = {};\n__export(v6_base_exports, {\n breakpoints: () => import_media2.breakpoints,\n createSystemFont: () => import_fonts2.createSystemFont,\n createV6Config: () => createV6Config,\n fonts: () => fonts,\n media: () => import_media2.media,\n mediaQueryDefaultActive: () => import_media2.mediaQueryDefaultActive,\n selectionStyles: () => import_settings.selectionStyles,\n settings: () => settings,\n shorthands: () => import_v6.shorthands,\n tailwindSource: () => import_v6_tailwind_scales2.tailwindSource,\n toV6Themes: () => import_v6_themes.toV6Themes,\n tokens: () => tokens,\n v6RemovedThemeNames: () => import_tooling.v6RemovedThemeNames,\n v6ThemeNameReplacements: () => import_tooling.v6ThemeNameReplacements\n});\nmodule.exports = __toCommonJS(v6_base_exports);\nvar import_v6 = require(\"@tamagui/shorthands/v6\");\nvar import_fonts = require(\"./fonts\");\nvar import_media = require(\"./media\");\nvar import_settings = require(\"./settings\");\nvar import_v6_tailwind_scales = require(\"./v6-tailwind-scales.generated\");\nvar import_fonts2 = require(\"./fonts\");\nvar import_media2 = require(\"./media\");\nvar import_v6_tailwind_scales2 = require(\"./v6-tailwind-scales.generated\");\nvar import_tooling = require(\"@tamagui/style-grammar/tooling\");\nvar import_v6_themes = require(\"./v6-themes\");\nvar tokens = {\n space: import_v6_tailwind_scales.tailwindSpace,\n size: import_v6_tailwind_scales.tailwindSize,\n radius: {\n 0: 0,\n 1: 3,\n 2: 5,\n 3: 7,\n 4: 9,\n 5: 10,\n 6: 16,\n 7: 19,\n 8: 22,\n 9: 26,\n 10: 34,\n 11: 42,\n 12: 50,\n ...import_v6_tailwind_scales.tailwindRadius\n }\n};\nfunction withTailwindTypeScale(font) {\n return {\n ...font,\n size: {\n ...font.size,\n ...import_v6_tailwind_scales.tailwindFontSize\n },\n lineHeight: {\n ...font.lineHeight,\n ...import_v6_tailwind_scales.tailwindLineHeight\n }\n };\n}\nvar fonts = {\n body: withTailwindTypeScale(import_fonts.fonts.body),\n heading: withTailwindTypeScale(import_fonts.fonts.heading)\n};\nvar settings = {\n ...import_settings.settings\n};\nfunction themesWithColorScales(themes, scales) {\n var _loop = function(name2) {\n var scale = scales[name2];\n if (scale.light.length !== 12 || scale.dark.length !== 12) {\n throw new Error(`color scale \"${name2}\" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);\n }\n scale.light.forEach(function(value, index) {\n light[`${name2}${index + 1}`] = value;\n });\n scale.dark.forEach(function(value, index) {\n dark[`${name2}${index + 1}`] = value;\n });\n };\n var light = {};\n var dark = {};\n for (var name in scales) _loop(name);\n return {\n ...themes,\n light: {\n ...themes.light,\n ...light\n },\n dark: {\n ...themes.dark,\n ...dark\n }\n };\n}\nvar alignedConfig = {\n media: import_media.media,\n shorthands: import_v6.shorthands,\n fonts,\n selectionStyles: import_settings.selectionStyles,\n settings\n};\nfunction createV6Config(colors) {\n return {\n ...alignedConfig,\n themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,\n tokens: colors.colorTokens ? {\n ...tokens,\n color: colors.colorTokens\n } : tokens\n };\n}\n//# sourceMappingURL=v6-base.js.map\n"],"mappings":";;;AACA,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC9B,KAAK,IAAI,QAAQ,KACf,UAAU,QAAQ,MAAM;EAAE,KAAK,IAAI;EAAO,YAAY;CAAK,CAAC;AAChE;AACA,IAAI,eAAe,IAAI,MAAM,QAAQ,SAAS;CAC5C,IAAI,QAAQ,OAAO,SAAS,YAAY,OAAO,SAAS,YAAY;EAClE,KAAK,IAAI,OAAO,kBAAkB,IAAI,GACpC,IAAI,CAAC,aAAa,KAAK,IAAI,GAAG,KAAK,QAAQ,QACzC,UAAU,IAAI,KAAK;GAAE,WAAW,KAAK;GAAM,YAAY,EAAE,OAAO,iBAAiB,MAAM,GAAG,MAAM,KAAK;EAAW,CAAC;CACvH;CACA,OAAO;AACT;AACA,IAAI,gBAAgB,QAAQ,YAAY,UAAU,CAAC,GAAG,cAAc,EAAE,OAAO,KAAK,CAAC,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ACA,IAAI,WAAW,EACb,GAAG,gBAAgB,SACrB;AACA,SAAS,sBAAsB,QAAQ,QAAQ;CAC7C,IAAI,QAAQ,SAAS,OAAO;EAC1B,IAAI,QAAQ,OAAO;EACnB,IAAI,MAAM,MAAM,WAAW,MAAM,MAAM,KAAK,WAAW,IAAI;GACzD,MAAM,IAAI,MAAM,gBAAgB,MAAM,mDAAmD,MAAM,MAAM,OAAO,GAAG,MAAM,KAAK,QAAQ;EACpI;EACA,MAAM,MAAM,QAAQ,SAAS,OAAO,OAAO;GACzC,MAAM,GAAG,QAAQ,QAAQ,OAAO;EAClC,CAAC;EACD,MAAM,KAAK,QAAQ,SAAS,OAAO,OAAO;GACxC,KAAK,GAAG,QAAQ,QAAQ,OAAO;EACjC,CAAC;CACH;CACA,IAAI,QAAQ,CAAC;CACb,IAAI,OAAO,CAAC;CACZ,KAAK,IAAI,QAAQ,QAAQ,MAAM,IAAI;CACnC,OAAO;EACL,GAAG;EACH,OAAO;GACL,GAAG,OAAO;GACV,GAAG;EACL;EACA,MAAM;GACJ,GAAG,OAAO;GACV,GAAG;EACL;CACF;AACF;AACA,IAAI,gBAAgB;CAClB,OAAO,aAAa;CACpB,YAAY,UAAU;CACtB;CACA,iBAAiB,gBAAgB;CACjC;AACF;AACA,SAAS,eAAe,QAAQ;CAC9B,OAAO;EACL,GAAG;EACH,QAAQ,OAAO,SAAS,sBAAsB,OAAO,QAAQ,OAAO,MAAM,IAAI,OAAO;EACrF,QAAQ,OAAO,cAAc;GAC3B,GAAG;GACH,OAAO,OAAO;EAChB,IAAI;CACN;AACF"}
|
package/dist/esm/v6-base.mjs
CHANGED
|
@@ -44,6 +44,33 @@ const fonts = {
|
|
|
44
44
|
heading: withTailwindTypeScale(fonts$1.heading)
|
|
45
45
|
};
|
|
46
46
|
const settings = { ...settings$1 };
|
|
47
|
+
function themesWithColorScales(themes, scales) {
|
|
48
|
+
const light = {};
|
|
49
|
+
const dark = {};
|
|
50
|
+
for (const name in scales) {
|
|
51
|
+
const scale = scales[name];
|
|
52
|
+
if (scale.light.length !== 12 || scale.dark.length !== 12) {
|
|
53
|
+
throw new Error(`color scale "${name}" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);
|
|
54
|
+
}
|
|
55
|
+
scale.light.forEach((value, index) => {
|
|
56
|
+
light[`${name}${index + 1}`] = value;
|
|
57
|
+
});
|
|
58
|
+
scale.dark.forEach((value, index) => {
|
|
59
|
+
dark[`${name}${index + 1}`] = value;
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
return {
|
|
63
|
+
...themes,
|
|
64
|
+
light: {
|
|
65
|
+
...themes.light,
|
|
66
|
+
...light
|
|
67
|
+
},
|
|
68
|
+
dark: {
|
|
69
|
+
...themes.dark,
|
|
70
|
+
...dark
|
|
71
|
+
}
|
|
72
|
+
};
|
|
73
|
+
}
|
|
47
74
|
const alignedConfig = {
|
|
48
75
|
media,
|
|
49
76
|
shorthands,
|
|
@@ -54,7 +81,7 @@ const alignedConfig = {
|
|
|
54
81
|
function createV6Config(colors) {
|
|
55
82
|
return {
|
|
56
83
|
...alignedConfig,
|
|
57
|
-
themes: colors.themes,
|
|
84
|
+
themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,
|
|
58
85
|
tokens: colors.colorTokens ? {
|
|
59
86
|
...tokens,
|
|
60
87
|
color: colors.colorTokens
|
package/dist/esm/v6-base.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v6-base.js","names":["systemFonts","baseSettings"],"sources":["esm/v6-base.js"],"sourcesContent":["import { shorthands } from \"@tamagui/shorthands/v6\";\nimport { fonts as systemFonts } from \"./fonts\";\nimport { media } from \"./media\";\nimport { selectionStyles, settings as baseSettings } from \"./settings\";\nimport {\n tailwindFontSize,\n tailwindLineHeight,\n tailwindRadius,\n tailwindSize,\n tailwindSpace\n} from \"./v6-tailwind-scales.generated\";\nimport { createSystemFont } from \"./fonts\";\nimport { breakpoints, media as media2, mediaQueryDefaultActive } from \"./media\";\nimport { tailwindSource } from \"./v6-tailwind-scales.generated\";\nimport {\n v6RemovedThemeNames,\n v6ThemeNameReplacements\n} from \"@tamagui/style-grammar/tooling\";\nimport { toV6Themes } from \"./v6-themes\";\nconst tokens = {\n space: tailwindSpace,\n size: tailwindSize,\n radius: {\n 0: 0,\n 1: 3,\n 2: 5,\n 3: 7,\n 4: 9,\n 5: 10,\n 6: 16,\n 7: 19,\n 8: 22,\n 9: 26,\n 10: 34,\n 11: 42,\n 12: 50,\n ...tailwindRadius\n }\n};\nfunction withTailwindTypeScale(font) {\n return {\n ...font,\n size: { ...font.size, ...tailwindFontSize },\n lineHeight: { ...font.lineHeight, ...tailwindLineHeight }\n };\n}\nconst fonts = {\n body: withTailwindTypeScale(systemFonts.body),\n heading: withTailwindTypeScale(systemFonts.heading)\n};\nconst settings = {\n ...baseSettings\n};\nconst alignedConfig = {\n media,\n shorthands,\n fonts,\n selectionStyles,\n settings\n};\nfunction createV6Config(colors) {\n return {\n ...alignedConfig,\n themes: colors.themes,\n tokens: colors.colorTokens ? { ...tokens, color: colors.colorTokens } : tokens\n };\n}\nexport {\n breakpoints,\n createSystemFont,\n createV6Config,\n fonts,\n media2 as media,\n mediaQueryDefaultActive,\n selectionStyles,\n settings,\n shorthands,\n tailwindSource,\n toV6Themes,\n tokens,\n v6RemovedThemeNames,\n v6ThemeNameReplacements\n};\n//# sourceMappingURL=v6-base.js.map\n"],"mappings":";;;;;;;;;AAmBA,MAAM,SAAS;CACb,OAAO;CACP,MAAM;CACN,QAAQ;EACN,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,IAAI;EACJ,IAAI;EACJ,IAAI;EACJ,GAAG;CACL;AACF;AACA,SAAS,sBAAsB,MAAM;CACnC,OAAO;EACL,GAAG;EACH,MAAM;GAAE,GAAG,KAAK;GAAM,GAAG;EAAiB;EAC1C,YAAY;GAAE,GAAG,KAAK;GAAY,GAAG;EAAmB;CAC1D;AACF;AACA,MAAM,QAAQ;CACZ,MAAM,sBAAsBA,QAAY,IAAI;CAC5C,SAAS,sBAAsBA,QAAY,OAAO;AACpD;AACA,MAAM,WAAW,EACf,GAAGC,WACL;AACA,MAAM,gBAAgB;CACpB;CACA;CACA;CACA;CACA;AACF;AACA,SAAS,eAAe,QAAQ;CAC9B,OAAO;EACL,GAAG;EACH,QAAQ,OAAO;
|
|
1
|
+
{"version":3,"file":"v6-base.js","names":["systemFonts","baseSettings"],"sources":["esm/v6-base.js"],"sourcesContent":["import { shorthands } from \"@tamagui/shorthands/v6\";\nimport { fonts as systemFonts } from \"./fonts\";\nimport { media } from \"./media\";\nimport { selectionStyles, settings as baseSettings } from \"./settings\";\nimport {\n tailwindFontSize,\n tailwindLineHeight,\n tailwindRadius,\n tailwindSize,\n tailwindSpace\n} from \"./v6-tailwind-scales.generated\";\nimport { createSystemFont } from \"./fonts\";\nimport { breakpoints, media as media2, mediaQueryDefaultActive } from \"./media\";\nimport { tailwindSource } from \"./v6-tailwind-scales.generated\";\nimport {\n v6RemovedThemeNames,\n v6ThemeNameReplacements\n} from \"@tamagui/style-grammar/tooling\";\nimport { toV6Themes } from \"./v6-themes\";\nconst tokens = {\n space: tailwindSpace,\n size: tailwindSize,\n radius: {\n 0: 0,\n 1: 3,\n 2: 5,\n 3: 7,\n 4: 9,\n 5: 10,\n 6: 16,\n 7: 19,\n 8: 22,\n 9: 26,\n 10: 34,\n 11: 42,\n 12: 50,\n ...tailwindRadius\n }\n};\nfunction withTailwindTypeScale(font) {\n return {\n ...font,\n size: { ...font.size, ...tailwindFontSize },\n lineHeight: { ...font.lineHeight, ...tailwindLineHeight }\n };\n}\nconst fonts = {\n body: withTailwindTypeScale(systemFonts.body),\n heading: withTailwindTypeScale(systemFonts.heading)\n};\nconst settings = {\n ...baseSettings\n};\nfunction themesWithColorScales(themes, scales) {\n const light = {};\n const dark = {};\n for (const name in scales) {\n const scale = scales[name];\n if (scale.light.length !== 12 || scale.dark.length !== 12) {\n throw new Error(\n `color scale \"${name}\" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`\n );\n }\n scale.light.forEach((value, index) => {\n light[`${name}${index + 1}`] = value;\n });\n scale.dark.forEach((value, index) => {\n dark[`${name}${index + 1}`] = value;\n });\n }\n return {\n ...themes,\n light: { ...themes.light, ...light },\n dark: { ...themes.dark, ...dark }\n };\n}\nconst alignedConfig = {\n media,\n shorthands,\n fonts,\n selectionStyles,\n settings\n};\nfunction createV6Config(colors) {\n return {\n ...alignedConfig,\n themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,\n tokens: colors.colorTokens ? { ...tokens, color: colors.colorTokens } : tokens\n };\n}\nexport {\n breakpoints,\n createSystemFont,\n createV6Config,\n fonts,\n media2 as media,\n mediaQueryDefaultActive,\n selectionStyles,\n settings,\n shorthands,\n tailwindSource,\n toV6Themes,\n tokens,\n v6RemovedThemeNames,\n v6ThemeNameReplacements\n};\n//# sourceMappingURL=v6-base.js.map\n"],"mappings":";;;;;;;;;AAmBA,MAAM,SAAS;CACb,OAAO;CACP,MAAM;CACN,QAAQ;EACN,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,IAAI;EACJ,IAAI;EACJ,IAAI;EACJ,GAAG;CACL;AACF;AACA,SAAS,sBAAsB,MAAM;CACnC,OAAO;EACL,GAAG;EACH,MAAM;GAAE,GAAG,KAAK;GAAM,GAAG;EAAiB;EAC1C,YAAY;GAAE,GAAG,KAAK;GAAY,GAAG;EAAmB;CAC1D;AACF;AACA,MAAM,QAAQ;CACZ,MAAM,sBAAsBA,QAAY,IAAI;CAC5C,SAAS,sBAAsBA,QAAY,OAAO;AACpD;AACA,MAAM,WAAW,EACf,GAAGC,WACL;AACA,SAAS,sBAAsB,QAAQ,QAAQ;CAC7C,MAAM,QAAQ,CAAC;CACf,MAAM,OAAO,CAAC;CACd,KAAK,MAAM,QAAQ,QAAQ;EACzB,MAAM,QAAQ,OAAO;EACrB,IAAI,MAAM,MAAM,WAAW,MAAM,MAAM,KAAK,WAAW,IAAI;GACzD,MAAM,IAAI,MACR,gBAAgB,KAAK,mDAAmD,MAAM,MAAM,OAAO,GAAG,MAAM,KAAK,QAC3G;EACF;EACA,MAAM,MAAM,SAAS,OAAO,UAAU;GACpC,MAAM,GAAG,OAAO,QAAQ,OAAO;EACjC,CAAC;EACD,MAAM,KAAK,SAAS,OAAO,UAAU;GACnC,KAAK,GAAG,OAAO,QAAQ,OAAO;EAChC,CAAC;CACH;CACA,OAAO;EACL,GAAG;EACH,OAAO;GAAE,GAAG,OAAO;GAAO,GAAG;EAAM;EACnC,MAAM;GAAE,GAAG,OAAO;GAAM,GAAG;EAAK;CAClC;AACF;AACA,MAAM,gBAAgB;CACpB;CACA;CACA;CACA;CACA;AACF;AACA,SAAS,eAAe,QAAQ;CAC9B,OAAO;EACL,GAAG;EACH,QAAQ,OAAO,SAAS,sBAAsB,OAAO,QAAQ,OAAO,MAAM,IAAI,OAAO;EACrF,QAAQ,OAAO,cAAc;GAAE,GAAG;GAAQ,OAAO,OAAO;EAAY,IAAI;CAC1E;AACF"}
|
|
@@ -44,6 +44,34 @@ var fonts = {
|
|
|
44
44
|
heading: withTailwindTypeScale(fonts$1.heading)
|
|
45
45
|
};
|
|
46
46
|
var settings = { ...settings$1 };
|
|
47
|
+
function themesWithColorScales(themes, scales) {
|
|
48
|
+
var _loop = function(name2) {
|
|
49
|
+
var scale = scales[name2];
|
|
50
|
+
if (scale.light.length !== 12 || scale.dark.length !== 12) {
|
|
51
|
+
throw new Error(`color scale "${name2}" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);
|
|
52
|
+
}
|
|
53
|
+
scale.light.forEach(function(value, index) {
|
|
54
|
+
light[`${name2}${index + 1}`] = value;
|
|
55
|
+
});
|
|
56
|
+
scale.dark.forEach(function(value, index) {
|
|
57
|
+
dark[`${name2}${index + 1}`] = value;
|
|
58
|
+
});
|
|
59
|
+
};
|
|
60
|
+
var light = {};
|
|
61
|
+
var dark = {};
|
|
62
|
+
for (var name in scales) _loop(name);
|
|
63
|
+
return {
|
|
64
|
+
...themes,
|
|
65
|
+
light: {
|
|
66
|
+
...themes.light,
|
|
67
|
+
...light
|
|
68
|
+
},
|
|
69
|
+
dark: {
|
|
70
|
+
...themes.dark,
|
|
71
|
+
...dark
|
|
72
|
+
}
|
|
73
|
+
};
|
|
74
|
+
}
|
|
47
75
|
var alignedConfig = {
|
|
48
76
|
media,
|
|
49
77
|
shorthands,
|
|
@@ -54,7 +82,7 @@ var alignedConfig = {
|
|
|
54
82
|
function createV6Config(colors) {
|
|
55
83
|
return {
|
|
56
84
|
...alignedConfig,
|
|
57
|
-
themes: colors.themes,
|
|
85
|
+
themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,
|
|
58
86
|
tokens: colors.colorTokens ? {
|
|
59
87
|
...tokens,
|
|
60
88
|
color: colors.colorTokens
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v6-base.native.js","names":["systemFonts","baseSettings"],"sources":["esm/v6-base.native.js"],"sourcesContent":["import { shorthands } from \"@tamagui/shorthands/v6\";\nimport { fonts as systemFonts } from \"./fonts\";\nimport { media } from \"./media\";\nimport { selectionStyles, settings as baseSettings } from \"./settings\";\nimport { tailwindFontSize, tailwindLineHeight, tailwindRadius, tailwindSize, tailwindSpace } from \"./v6-tailwind-scales.generated\";\nimport { createSystemFont } from \"./fonts\";\nimport { breakpoints, media as media2, mediaQueryDefaultActive } from \"./media\";\nimport { tailwindSource } from \"./v6-tailwind-scales.generated\";\nimport { v6RemovedThemeNames, v6ThemeNameReplacements } from \"@tamagui/style-grammar/tooling\";\nimport { toV6Themes } from \"./v6-themes\";\nvar tokens = {\n space: tailwindSpace,\n size: tailwindSize,\n radius: {\n 0: 0,\n 1: 3,\n 2: 5,\n 3: 7,\n 4: 9,\n 5: 10,\n 6: 16,\n 7: 19,\n 8: 22,\n 9: 26,\n 10: 34,\n 11: 42,\n 12: 50,\n ...tailwindRadius\n }\n};\nfunction withTailwindTypeScale(font) {\n return {\n ...font,\n size: {\n ...font.size,\n ...tailwindFontSize\n },\n lineHeight: {\n ...font.lineHeight,\n ...tailwindLineHeight\n }\n };\n}\nvar fonts = {\n body: withTailwindTypeScale(systemFonts.body),\n heading: withTailwindTypeScale(systemFonts.heading)\n};\nvar settings = {\n ...baseSettings\n};\nvar alignedConfig = {\n media,\n shorthands,\n fonts,\n selectionStyles,\n settings\n};\nfunction createV6Config(colors) {\n return {\n ...alignedConfig,\n themes: colors.themes,\n tokens: colors.colorTokens ? {\n ...tokens,\n color: colors.colorTokens\n } : tokens\n };\n}\nexport {\n breakpoints,\n createSystemFont,\n createV6Config,\n fonts,\n media2 as media,\n mediaQueryDefaultActive,\n selectionStyles,\n settings,\n shorthands,\n tailwindSource,\n toV6Themes,\n tokens,\n v6RemovedThemeNames,\n v6ThemeNameReplacements\n};\n//# sourceMappingURL=v6-base.js.map\n"],"mappings":";;;;;;;;;AAUA,IAAI,SAAS;CACX,OAAO;CACP,MAAM;CACN,QAAQ;EACN,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,IAAI;EACJ,IAAI;EACJ,IAAI;EACJ,GAAG;CACL;AACF;AACA,SAAS,sBAAsB,MAAM;CACnC,OAAO;EACL,GAAG;EACH,MAAM;GACJ,GAAG,KAAK;GACR,GAAG;EACL;EACA,YAAY;GACV,GAAG,KAAK;GACR,GAAG;EACL;CACF;AACF;AACA,IAAI,QAAQ;CACV,MAAM,sBAAsBA,QAAY,IAAI;CAC5C,SAAS,sBAAsBA,QAAY,OAAO;AACpD;AACA,IAAI,WAAW,EACb,GAAGC,WACL;AACA,IAAI,gBAAgB;CAClB;CACA;CACA;CACA;CACA;AACF;AACA,SAAS,eAAe,QAAQ;CAC9B,OAAO;EACL,GAAG;EACH,QAAQ,OAAO;
|
|
1
|
+
{"version":3,"file":"v6-base.native.js","names":["systemFonts","baseSettings"],"sources":["esm/v6-base.native.js"],"sourcesContent":["import { shorthands } from \"@tamagui/shorthands/v6\";\nimport { fonts as systemFonts } from \"./fonts\";\nimport { media } from \"./media\";\nimport { selectionStyles, settings as baseSettings } from \"./settings\";\nimport { tailwindFontSize, tailwindLineHeight, tailwindRadius, tailwindSize, tailwindSpace } from \"./v6-tailwind-scales.generated\";\nimport { createSystemFont } from \"./fonts\";\nimport { breakpoints, media as media2, mediaQueryDefaultActive } from \"./media\";\nimport { tailwindSource } from \"./v6-tailwind-scales.generated\";\nimport { v6RemovedThemeNames, v6ThemeNameReplacements } from \"@tamagui/style-grammar/tooling\";\nimport { toV6Themes } from \"./v6-themes\";\nvar tokens = {\n space: tailwindSpace,\n size: tailwindSize,\n radius: {\n 0: 0,\n 1: 3,\n 2: 5,\n 3: 7,\n 4: 9,\n 5: 10,\n 6: 16,\n 7: 19,\n 8: 22,\n 9: 26,\n 10: 34,\n 11: 42,\n 12: 50,\n ...tailwindRadius\n }\n};\nfunction withTailwindTypeScale(font) {\n return {\n ...font,\n size: {\n ...font.size,\n ...tailwindFontSize\n },\n lineHeight: {\n ...font.lineHeight,\n ...tailwindLineHeight\n }\n };\n}\nvar fonts = {\n body: withTailwindTypeScale(systemFonts.body),\n heading: withTailwindTypeScale(systemFonts.heading)\n};\nvar settings = {\n ...baseSettings\n};\nfunction themesWithColorScales(themes, scales) {\n var _loop = function(name2) {\n var scale = scales[name2];\n if (scale.light.length !== 12 || scale.dark.length !== 12) {\n throw new Error(`color scale \"${name2}\" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`);\n }\n scale.light.forEach(function(value, index) {\n light[`${name2}${index + 1}`] = value;\n });\n scale.dark.forEach(function(value, index) {\n dark[`${name2}${index + 1}`] = value;\n });\n };\n var light = {};\n var dark = {};\n for (var name in scales) _loop(name);\n return {\n ...themes,\n light: {\n ...themes.light,\n ...light\n },\n dark: {\n ...themes.dark,\n ...dark\n }\n };\n}\nvar alignedConfig = {\n media,\n shorthands,\n fonts,\n selectionStyles,\n settings\n};\nfunction createV6Config(colors) {\n return {\n ...alignedConfig,\n themes: colors.scales ? themesWithColorScales(colors.themes, colors.scales) : colors.themes,\n tokens: colors.colorTokens ? {\n ...tokens,\n color: colors.colorTokens\n } : tokens\n };\n}\nexport {\n breakpoints,\n createSystemFont,\n createV6Config,\n fonts,\n media2 as media,\n mediaQueryDefaultActive,\n selectionStyles,\n settings,\n shorthands,\n tailwindSource,\n toV6Themes,\n tokens,\n v6RemovedThemeNames,\n v6ThemeNameReplacements\n};\n//# sourceMappingURL=v6-base.js.map\n"],"mappings":";;;;;;;;;AAUA,IAAI,SAAS;CACX,OAAO;CACP,MAAM;CACN,QAAQ;EACN,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,GAAG;EACH,IAAI;EACJ,IAAI;EACJ,IAAI;EACJ,GAAG;CACL;AACF;AACA,SAAS,sBAAsB,MAAM;CACnC,OAAO;EACL,GAAG;EACH,MAAM;GACJ,GAAG,KAAK;GACR,GAAG;EACL;EACA,YAAY;GACV,GAAG,KAAK;GACR,GAAG;EACL;CACF;AACF;AACA,IAAI,QAAQ;CACV,MAAM,sBAAsBA,QAAY,IAAI;CAC5C,SAAS,sBAAsBA,QAAY,OAAO;AACpD;AACA,IAAI,WAAW,EACb,GAAGC,WACL;AACA,SAAS,sBAAsB,QAAQ,QAAQ;CAC7C,IAAI,QAAQ,SAAS,OAAO;EAC1B,IAAI,QAAQ,OAAO;EACnB,IAAI,MAAM,MAAM,WAAW,MAAM,MAAM,KAAK,WAAW,IAAI;GACzD,MAAM,IAAI,MAAM,gBAAgB,MAAM,mDAAmD,MAAM,MAAM,OAAO,GAAG,MAAM,KAAK,QAAQ;EACpI;EACA,MAAM,MAAM,QAAQ,SAAS,OAAO,OAAO;GACzC,MAAM,GAAG,QAAQ,QAAQ,OAAO;EAClC,CAAC;EACD,MAAM,KAAK,QAAQ,SAAS,OAAO,OAAO;GACxC,KAAK,GAAG,QAAQ,QAAQ,OAAO;EACjC,CAAC;CACH;CACA,IAAI,QAAQ,CAAC;CACb,IAAI,OAAO,CAAC;CACZ,KAAK,IAAI,QAAQ,QAAQ,MAAM,IAAI;CACnC,OAAO;EACL,GAAG;EACH,OAAO;GACL,GAAG,OAAO;GACV,GAAG;EACL;EACA,MAAM;GACJ,GAAG,OAAO;GACV,GAAG;EACL;CACF;AACF;AACA,IAAI,gBAAgB;CAClB;CACA;CACA;CACA;CACA;AACF;AACA,SAAS,eAAe,QAAQ;CAC9B,OAAO;EACL,GAAG;EACH,QAAQ,OAAO,SAAS,sBAAsB,OAAO,QAAQ,OAAO,MAAM,IAAI,OAAO;EACrF,QAAQ,OAAO,cAAc;GAC3B,GAAG;GACH,OAAO,OAAO;EAChB,IAAI;CACN;AACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tamagui/config",
|
|
3
|
-
"version": "3.0.0-beta.
|
|
3
|
+
"version": "3.0.0-beta.765.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"files": [
|
|
@@ -167,20 +167,20 @@
|
|
|
167
167
|
"clean:build": "tamagui-build clean:build"
|
|
168
168
|
},
|
|
169
169
|
"dependencies": {
|
|
170
|
-
"@tamagui/animations-css": "3.0.0-beta.
|
|
171
|
-
"@tamagui/animations-motion": "3.0.0-beta.
|
|
172
|
-
"@tamagui/animations-react-native": "3.0.0-beta.
|
|
173
|
-
"@tamagui/animations-reanimated": "3.0.0-beta.
|
|
174
|
-
"@tamagui/create-system-font": "3.0.0-beta.
|
|
175
|
-
"@tamagui/shorthands": "3.0.0-beta.
|
|
176
|
-
"@tamagui/style-grammar": "3.0.0-beta.
|
|
177
|
-
"@tamagui/themes": "3.0.0-beta.
|
|
178
|
-
"@tamagui/web": "3.0.0-beta.
|
|
170
|
+
"@tamagui/animations-css": "3.0.0-beta.765.1",
|
|
171
|
+
"@tamagui/animations-motion": "3.0.0-beta.765.1",
|
|
172
|
+
"@tamagui/animations-react-native": "3.0.0-beta.765.1",
|
|
173
|
+
"@tamagui/animations-reanimated": "3.0.0-beta.765.1",
|
|
174
|
+
"@tamagui/create-system-font": "3.0.0-beta.765.1",
|
|
175
|
+
"@tamagui/shorthands": "3.0.0-beta.765.1",
|
|
176
|
+
"@tamagui/style-grammar": "3.0.0-beta.765.1",
|
|
177
|
+
"@tamagui/themes": "3.0.0-beta.765.1",
|
|
178
|
+
"@tamagui/web": "3.0.0-beta.765.1"
|
|
179
179
|
},
|
|
180
180
|
"devDependencies": {
|
|
181
181
|
"@csstools/color-helpers": "6.1.0",
|
|
182
|
-
"@tamagui/build": "3.0.0-beta.
|
|
183
|
-
"@tamagui/cli": "3.0.0-beta.
|
|
182
|
+
"@tamagui/build": "3.0.0-beta.765.1",
|
|
183
|
+
"@tamagui/cli": "3.0.0-beta.765.1",
|
|
184
184
|
"tailwindcss": "4.3.0"
|
|
185
185
|
},
|
|
186
186
|
"repository": {
|
package/src/v6-base.ts
CHANGED
|
@@ -73,6 +73,75 @@ export type V6Colors = {
|
|
|
73
73
|
themes: NonNullable<CreateTamaguiProps['themes']>
|
|
74
74
|
/** flat named colors added at tokens.color */
|
|
75
75
|
colorTokens?: Record<string, string>
|
|
76
|
+
/** extra 12-step color scales merged into the light and dark base themes */
|
|
77
|
+
scales?: V6ColorScales
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
type Twelve<Value> = readonly [
|
|
81
|
+
Value,
|
|
82
|
+
Value,
|
|
83
|
+
Value,
|
|
84
|
+
Value,
|
|
85
|
+
Value,
|
|
86
|
+
Value,
|
|
87
|
+
Value,
|
|
88
|
+
Value,
|
|
89
|
+
Value,
|
|
90
|
+
Value,
|
|
91
|
+
Value,
|
|
92
|
+
Value,
|
|
93
|
+
]
|
|
94
|
+
|
|
95
|
+
/** one 12-step scale, light and dark values from step 1 (faintest) to 12 (strongest) */
|
|
96
|
+
export type V6ColorScale = {
|
|
97
|
+
light: Twelve<string>
|
|
98
|
+
dark: Twelve<string>
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export type V6ColorScales = Record<string, V6ColorScale>
|
|
102
|
+
|
|
103
|
+
type ScaleStep = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12
|
|
104
|
+
|
|
105
|
+
type ColorScaleThemeKeys<Scales extends V6ColorScales> = {
|
|
106
|
+
[Name in keyof Scales & string as `${Name}${ScaleStep}`]: string
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
type WithColorScales<
|
|
110
|
+
Themes extends Record<string, object>,
|
|
111
|
+
Scales extends V6ColorScales,
|
|
112
|
+
> = {
|
|
113
|
+
[Name in keyof Themes]: Name extends 'light' | 'dark'
|
|
114
|
+
? Themes[Name] & ColorScaleThemeKeys<Scales>
|
|
115
|
+
: Themes[Name]
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
// scale keys land only on the base light/dark themes; every subtheme reaches
|
|
119
|
+
// them through parent fallback, so the CSS carries each value once
|
|
120
|
+
function themesWithColorScales<
|
|
121
|
+
Themes extends Record<string, object>,
|
|
122
|
+
Scales extends V6ColorScales,
|
|
123
|
+
>(themes: Themes, scales: Scales): WithColorScales<Themes, Scales> {
|
|
124
|
+
const light: Record<string, string> = {}
|
|
125
|
+
const dark: Record<string, string> = {}
|
|
126
|
+
for (const name in scales) {
|
|
127
|
+
const scale = scales[name]
|
|
128
|
+
if (scale.light.length !== 12 || scale.dark.length !== 12) {
|
|
129
|
+
throw new Error(
|
|
130
|
+
`color scale "${name}" needs exactly 12 light and 12 dark values, got ${scale.light.length}/${scale.dark.length}`
|
|
131
|
+
)
|
|
132
|
+
}
|
|
133
|
+
scale.light.forEach((value, index) => {
|
|
134
|
+
light[`${name}${index + 1}`] = value
|
|
135
|
+
})
|
|
136
|
+
scale.dark.forEach((value, index) => {
|
|
137
|
+
dark[`${name}${index + 1}`] = value
|
|
138
|
+
})
|
|
139
|
+
}
|
|
140
|
+
return {
|
|
141
|
+
...themes,
|
|
142
|
+
light: { ...themes.light, ...light },
|
|
143
|
+
dark: { ...themes.dark, ...dark },
|
|
144
|
+
} as WithColorScales<Themes, Scales>
|
|
76
145
|
}
|
|
77
146
|
|
|
78
147
|
const alignedConfig = {
|
|
@@ -87,26 +156,32 @@ const alignedConfig = {
|
|
|
87
156
|
export function createV6Config<
|
|
88
157
|
Themes extends NonNullable<CreateTamaguiProps['themes']>,
|
|
89
158
|
ColorTokens extends Record<string, string>,
|
|
159
|
+
Scales extends V6ColorScales = Record<never, V6ColorScale>,
|
|
90
160
|
>(colors: {
|
|
91
161
|
themes: Themes
|
|
92
162
|
colorTokens: ColorTokens
|
|
163
|
+
scales?: Scales
|
|
93
164
|
}): typeof alignedConfig & {
|
|
94
|
-
themes: Themes
|
|
165
|
+
themes: WithColorScales<Themes, Scales>
|
|
95
166
|
tokens: typeof tokens & { color: ColorTokens }
|
|
96
167
|
}
|
|
97
168
|
export function createV6Config<
|
|
98
169
|
Themes extends NonNullable<CreateTamaguiProps['themes']>,
|
|
170
|
+
Scales extends V6ColorScales = Record<never, V6ColorScale>,
|
|
99
171
|
>(colors: {
|
|
100
172
|
themes: Themes
|
|
101
173
|
colorTokens?: undefined
|
|
174
|
+
scales?: Scales
|
|
102
175
|
}): typeof alignedConfig & {
|
|
103
|
-
themes: Themes
|
|
176
|
+
themes: WithColorScales<Themes, Scales>
|
|
104
177
|
tokens: typeof tokens
|
|
105
178
|
}
|
|
106
179
|
export function createV6Config(colors: V6Colors) {
|
|
107
180
|
return {
|
|
108
181
|
...alignedConfig,
|
|
109
|
-
themes: colors.
|
|
182
|
+
themes: colors.scales
|
|
183
|
+
? themesWithColorScales(colors.themes, colors.scales)
|
|
184
|
+
: colors.themes,
|
|
110
185
|
tokens: colors.colorTokens ? { ...tokens, color: colors.colorTokens } : tokens,
|
|
111
186
|
}
|
|
112
187
|
}
|
package/types/v6-base.d.ts
CHANGED
|
@@ -252,6 +252,35 @@ export type V6Colors = {
|
|
|
252
252
|
themes: NonNullable<CreateTamaguiProps['themes']>;
|
|
253
253
|
/** flat named colors added at tokens.color */
|
|
254
254
|
colorTokens?: Record<string, string>;
|
|
255
|
+
/** extra 12-step color scales merged into the light and dark base themes */
|
|
256
|
+
scales?: V6ColorScales;
|
|
257
|
+
};
|
|
258
|
+
type Twelve<Value> = readonly [
|
|
259
|
+
Value,
|
|
260
|
+
Value,
|
|
261
|
+
Value,
|
|
262
|
+
Value,
|
|
263
|
+
Value,
|
|
264
|
+
Value,
|
|
265
|
+
Value,
|
|
266
|
+
Value,
|
|
267
|
+
Value,
|
|
268
|
+
Value,
|
|
269
|
+
Value,
|
|
270
|
+
Value
|
|
271
|
+
];
|
|
272
|
+
/** one 12-step scale, light and dark values from step 1 (faintest) to 12 (strongest) */
|
|
273
|
+
export type V6ColorScale = {
|
|
274
|
+
light: Twelve<string>;
|
|
275
|
+
dark: Twelve<string>;
|
|
276
|
+
};
|
|
277
|
+
export type V6ColorScales = Record<string, V6ColorScale>;
|
|
278
|
+
type ScaleStep = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
279
|
+
type ColorScaleThemeKeys<Scales extends V6ColorScales> = {
|
|
280
|
+
[Name in keyof Scales & string as `${Name}${ScaleStep}`]: string;
|
|
281
|
+
};
|
|
282
|
+
type WithColorScales<Themes extends Record<string, object>, Scales extends V6ColorScales> = {
|
|
283
|
+
[Name in keyof Themes]: Name extends 'light' | 'dark' ? Themes[Name] & ColorScaleThemeKeys<Scales> : Themes[Name];
|
|
255
284
|
};
|
|
256
285
|
declare const alignedConfig: {
|
|
257
286
|
media: {
|
|
@@ -490,20 +519,22 @@ declare const alignedConfig: {
|
|
|
490
519
|
};
|
|
491
520
|
};
|
|
492
521
|
/** Compose the aligned v6 base with a colors pack into a createTamagui-ready config. */
|
|
493
|
-
export declare function createV6Config<Themes extends NonNullable<CreateTamaguiProps['themes']>, ColorTokens extends Record<string, string>>(colors: {
|
|
522
|
+
export declare function createV6Config<Themes extends NonNullable<CreateTamaguiProps['themes']>, ColorTokens extends Record<string, string>, Scales extends V6ColorScales = Record<never, V6ColorScale>>(colors: {
|
|
494
523
|
themes: Themes;
|
|
495
524
|
colorTokens: ColorTokens;
|
|
525
|
+
scales?: Scales;
|
|
496
526
|
}): typeof alignedConfig & {
|
|
497
|
-
themes: Themes
|
|
527
|
+
themes: WithColorScales<Themes, Scales>;
|
|
498
528
|
tokens: typeof tokens & {
|
|
499
529
|
color: ColorTokens;
|
|
500
530
|
};
|
|
501
531
|
};
|
|
502
|
-
export declare function createV6Config<Themes extends NonNullable<CreateTamaguiProps['themes']>>(colors: {
|
|
532
|
+
export declare function createV6Config<Themes extends NonNullable<CreateTamaguiProps['themes']>, Scales extends V6ColorScales = Record<never, V6ColorScale>>(colors: {
|
|
503
533
|
themes: Themes;
|
|
504
534
|
colorTokens?: undefined;
|
|
535
|
+
scales?: Scales;
|
|
505
536
|
}): typeof alignedConfig & {
|
|
506
|
-
themes: Themes
|
|
537
|
+
themes: WithColorScales<Themes, Scales>;
|
|
507
538
|
tokens: typeof tokens;
|
|
508
539
|
};
|
|
509
540
|
//# sourceMappingURL=v6-base.d.ts.map
|
package/types/v6-base.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v6-base.d.ts","sourceRoot":"","sources":["../src/v6-base.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAA;AACnD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAGtD,OAAO,EAAE,eAAe,E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B,CAAA"}
|
package/types/v6.d.ts
CHANGED
|
@@ -992,7 +992,136 @@ export declare const defaultConfig: {
|
|
|
992
992
|
styleCompat: "web";
|
|
993
993
|
};
|
|
994
994
|
} & {
|
|
995
|
-
themes:
|
|
995
|
+
themes: {
|
|
996
|
+
dark: Theme & {};
|
|
997
|
+
dark_accent: Theme;
|
|
998
|
+
dark_accent_level2: Theme;
|
|
999
|
+
dark_accent_level2_level2: Theme;
|
|
1000
|
+
dark_accent_level2_level2_level2: Theme;
|
|
1001
|
+
dark_accent_level2_level2_level3: Theme;
|
|
1002
|
+
dark_accent_level2_level2_level4: Theme;
|
|
1003
|
+
dark_accent_level2_level3: Theme;
|
|
1004
|
+
dark_accent_level2_level4: Theme;
|
|
1005
|
+
dark_accent_level3: Theme;
|
|
1006
|
+
dark_accent_level3_level2: Theme;
|
|
1007
|
+
dark_accent_level3_level3: Theme;
|
|
1008
|
+
dark_accent_level3_level4: Theme;
|
|
1009
|
+
dark_accent_level4: Theme;
|
|
1010
|
+
dark_brand: Theme;
|
|
1011
|
+
dark_brand_level2: Theme;
|
|
1012
|
+
dark_brand_level2_level2: Theme;
|
|
1013
|
+
dark_brand_level2_level2_level2: Theme;
|
|
1014
|
+
dark_brand_level2_level2_level3: Theme;
|
|
1015
|
+
dark_brand_level2_level2_level4: Theme;
|
|
1016
|
+
dark_brand_level2_level3: Theme;
|
|
1017
|
+
dark_brand_level2_level4: Theme;
|
|
1018
|
+
dark_brand_level3: Theme;
|
|
1019
|
+
dark_brand_level3_level2: Theme;
|
|
1020
|
+
dark_brand_level3_level3: Theme;
|
|
1021
|
+
dark_brand_level3_level4: Theme;
|
|
1022
|
+
dark_brand_level4: Theme;
|
|
1023
|
+
dark_green: Theme;
|
|
1024
|
+
dark_green_level2: Theme;
|
|
1025
|
+
dark_green_level3: Theme;
|
|
1026
|
+
dark_green_level4: Theme;
|
|
1027
|
+
dark_inverse: Theme;
|
|
1028
|
+
dark_inverse_level2: Theme;
|
|
1029
|
+
dark_inverse_level2_level2: Theme;
|
|
1030
|
+
dark_inverse_level2_level2_level2: Theme;
|
|
1031
|
+
dark_inverse_level2_level2_level3: Theme;
|
|
1032
|
+
dark_inverse_level2_level2_level4: Theme;
|
|
1033
|
+
dark_inverse_level2_level3: Theme;
|
|
1034
|
+
dark_inverse_level2_level4: Theme;
|
|
1035
|
+
dark_inverse_level3: Theme;
|
|
1036
|
+
dark_inverse_level3_level2: Theme;
|
|
1037
|
+
dark_inverse_level3_level3: Theme;
|
|
1038
|
+
dark_inverse_level3_level4: Theme;
|
|
1039
|
+
dark_inverse_level4: Theme;
|
|
1040
|
+
dark_level2: Theme;
|
|
1041
|
+
dark_level2_level2: Theme;
|
|
1042
|
+
dark_level2_level2_level2: Theme;
|
|
1043
|
+
dark_level2_level2_level3: Theme;
|
|
1044
|
+
dark_level2_level2_level4: Theme;
|
|
1045
|
+
dark_level2_level3: Theme;
|
|
1046
|
+
dark_level2_level4: Theme;
|
|
1047
|
+
dark_level3: Theme;
|
|
1048
|
+
dark_level3_level2: Theme;
|
|
1049
|
+
dark_level3_level3: Theme;
|
|
1050
|
+
dark_level3_level4: Theme;
|
|
1051
|
+
dark_level4: Theme;
|
|
1052
|
+
dark_red: Theme;
|
|
1053
|
+
dark_red_level2: Theme;
|
|
1054
|
+
dark_red_level3: Theme;
|
|
1055
|
+
dark_red_level4: Theme;
|
|
1056
|
+
dark_yellow: Theme;
|
|
1057
|
+
dark_yellow_level2: Theme;
|
|
1058
|
+
dark_yellow_level3: Theme;
|
|
1059
|
+
dark_yellow_level4: Theme;
|
|
1060
|
+
light: Theme & {};
|
|
1061
|
+
light_accent: Theme;
|
|
1062
|
+
light_accent_level2: Theme;
|
|
1063
|
+
light_accent_level2_level2: Theme;
|
|
1064
|
+
light_accent_level2_level2_level2: Theme;
|
|
1065
|
+
light_accent_level2_level2_level3: Theme;
|
|
1066
|
+
light_accent_level2_level2_level4: Theme;
|
|
1067
|
+
light_accent_level2_level3: Theme;
|
|
1068
|
+
light_accent_level2_level4: Theme;
|
|
1069
|
+
light_accent_level3: Theme;
|
|
1070
|
+
light_accent_level3_level2: Theme;
|
|
1071
|
+
light_accent_level3_level3: Theme;
|
|
1072
|
+
light_accent_level3_level4: Theme;
|
|
1073
|
+
light_accent_level4: Theme;
|
|
1074
|
+
light_brand: Theme;
|
|
1075
|
+
light_brand_level2: Theme;
|
|
1076
|
+
light_brand_level2_level2: Theme;
|
|
1077
|
+
light_brand_level2_level2_level2: Theme;
|
|
1078
|
+
light_brand_level2_level2_level3: Theme;
|
|
1079
|
+
light_brand_level2_level2_level4: Theme;
|
|
1080
|
+
light_brand_level2_level3: Theme;
|
|
1081
|
+
light_brand_level2_level4: Theme;
|
|
1082
|
+
light_brand_level3: Theme;
|
|
1083
|
+
light_brand_level3_level2: Theme;
|
|
1084
|
+
light_brand_level3_level3: Theme;
|
|
1085
|
+
light_brand_level3_level4: Theme;
|
|
1086
|
+
light_brand_level4: Theme;
|
|
1087
|
+
light_green: Theme;
|
|
1088
|
+
light_green_level2: Theme;
|
|
1089
|
+
light_green_level3: Theme;
|
|
1090
|
+
light_green_level4: Theme;
|
|
1091
|
+
light_inverse: Theme;
|
|
1092
|
+
light_inverse_level2: Theme;
|
|
1093
|
+
light_inverse_level2_level2: Theme;
|
|
1094
|
+
light_inverse_level2_level2_level2: Theme;
|
|
1095
|
+
light_inverse_level2_level2_level3: Theme;
|
|
1096
|
+
light_inverse_level2_level2_level4: Theme;
|
|
1097
|
+
light_inverse_level2_level3: Theme;
|
|
1098
|
+
light_inverse_level2_level4: Theme;
|
|
1099
|
+
light_inverse_level3: Theme;
|
|
1100
|
+
light_inverse_level3_level2: Theme;
|
|
1101
|
+
light_inverse_level3_level3: Theme;
|
|
1102
|
+
light_inverse_level3_level4: Theme;
|
|
1103
|
+
light_inverse_level4: Theme;
|
|
1104
|
+
light_level2: Theme;
|
|
1105
|
+
light_level2_level2: Theme;
|
|
1106
|
+
light_level2_level2_level2: Theme;
|
|
1107
|
+
light_level2_level2_level3: Theme;
|
|
1108
|
+
light_level2_level2_level4: Theme;
|
|
1109
|
+
light_level2_level3: Theme;
|
|
1110
|
+
light_level2_level4: Theme;
|
|
1111
|
+
light_level3: Theme;
|
|
1112
|
+
light_level3_level2: Theme;
|
|
1113
|
+
light_level3_level3: Theme;
|
|
1114
|
+
light_level3_level4: Theme;
|
|
1115
|
+
light_level4: Theme;
|
|
1116
|
+
light_red: Theme;
|
|
1117
|
+
light_red_level2: Theme;
|
|
1118
|
+
light_red_level3: Theme;
|
|
1119
|
+
light_red_level4: Theme;
|
|
1120
|
+
light_yellow: Theme;
|
|
1121
|
+
light_yellow_level2: Theme;
|
|
1122
|
+
light_yellow_level3: Theme;
|
|
1123
|
+
light_yellow_level4: Theme;
|
|
1124
|
+
};
|
|
996
1125
|
tokens: {
|
|
997
1126
|
readonly space: {
|
|
998
1127
|
readonly '0': 0;
|
package/types/v6.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v6.d.ts","sourceRoot":"","sources":["../src/v6.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,cAAc,EACd,MAAM,EAEN,KAAK,KAAK,EACV,KAAK,UAAU,EACf,KAAK,MAAM,EACZ,MAAM,iBAAiB,CAAA;AAKxB,cAAc,WAAW,CAAA;AACzB,OAAO,EAAE,cAAc,EAAE,MAAM,EAAE,CAAA;AACjC,YAAY,EAAE,KAAK,IAAI,OAAO,EAAE,UAAU,IAAI,YAAY,EAAE,MAAM,IAAI,QAAQ,EAAE,CAAA;AAEhF,sFAAsF;AACtF,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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