@storybook/react-native-theming 9.0.0-alpha.8 → 9.0.0-beta.10
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/index.d.ts +108 -108
- package/dist/index.js +389 -389
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -3,114 +3,6 @@ import { ImageSourcePropType, ImageProps, TextStyle } from 'react-native';
|
|
|
3
3
|
import * as React$1 from 'react';
|
|
4
4
|
import { ReactElement } from 'react';
|
|
5
5
|
|
|
6
|
-
declare const color: {
|
|
7
|
-
primary: string;
|
|
8
|
-
secondary: string;
|
|
9
|
-
secondaryLighter: string;
|
|
10
|
-
tertiary: string;
|
|
11
|
-
ancillary: string;
|
|
12
|
-
orange: string;
|
|
13
|
-
gold: string;
|
|
14
|
-
green: string;
|
|
15
|
-
seafoam: string;
|
|
16
|
-
purple: string;
|
|
17
|
-
ultraviolet: string;
|
|
18
|
-
lightest: string;
|
|
19
|
-
lighter: string;
|
|
20
|
-
light: string;
|
|
21
|
-
mediumlight: string;
|
|
22
|
-
medium: string;
|
|
23
|
-
mediumdark: string;
|
|
24
|
-
dark: string;
|
|
25
|
-
darker: string;
|
|
26
|
-
darkest: string;
|
|
27
|
-
border: string;
|
|
28
|
-
positive: string;
|
|
29
|
-
negative: string;
|
|
30
|
-
warning: string;
|
|
31
|
-
critical: string;
|
|
32
|
-
defaultText: string;
|
|
33
|
-
inverseText: string;
|
|
34
|
-
positiveText: string;
|
|
35
|
-
negativeText: string;
|
|
36
|
-
warningText: string;
|
|
37
|
-
};
|
|
38
|
-
declare const background: {
|
|
39
|
-
app: string;
|
|
40
|
-
bar: string;
|
|
41
|
-
content: string;
|
|
42
|
-
preview: string;
|
|
43
|
-
gridCellSize: number;
|
|
44
|
-
hoverable: string;
|
|
45
|
-
positive: string;
|
|
46
|
-
negative: string;
|
|
47
|
-
warning: string;
|
|
48
|
-
critical: string;
|
|
49
|
-
};
|
|
50
|
-
declare const typography: {
|
|
51
|
-
weight: {
|
|
52
|
-
regular: TextStyle["fontWeight"];
|
|
53
|
-
bold: TextStyle["fontWeight"];
|
|
54
|
-
};
|
|
55
|
-
size: {
|
|
56
|
-
s1: number;
|
|
57
|
-
s2: number;
|
|
58
|
-
s3: number;
|
|
59
|
-
m1: number;
|
|
60
|
-
m2: number;
|
|
61
|
-
m3: number;
|
|
62
|
-
l1: number;
|
|
63
|
-
l2: number;
|
|
64
|
-
l3: number;
|
|
65
|
-
code: number;
|
|
66
|
-
};
|
|
67
|
-
};
|
|
68
|
-
type Color = typeof color;
|
|
69
|
-
type Background = typeof background;
|
|
70
|
-
type Typography = typeof typography;
|
|
71
|
-
interface Brand {
|
|
72
|
-
title?: string | undefined;
|
|
73
|
-
url?: string | null | undefined;
|
|
74
|
-
image?: ImageSourcePropType | ReactElement | null | undefined;
|
|
75
|
-
resizeMode?: ImageProps['resizeMode'] | null | undefined;
|
|
76
|
-
target?: string | null | undefined;
|
|
77
|
-
}
|
|
78
|
-
interface StorybookThemeWeb {
|
|
79
|
-
base: 'light' | 'dark';
|
|
80
|
-
color: Color;
|
|
81
|
-
background: Background;
|
|
82
|
-
typography: Typography;
|
|
83
|
-
textMutedColor: string;
|
|
84
|
-
input: {
|
|
85
|
-
border: string;
|
|
86
|
-
background: string;
|
|
87
|
-
color: string;
|
|
88
|
-
borderRadius: number;
|
|
89
|
-
paddingHorizontal: number;
|
|
90
|
-
paddingVertical: number;
|
|
91
|
-
};
|
|
92
|
-
button: {
|
|
93
|
-
background: string;
|
|
94
|
-
border: string;
|
|
95
|
-
};
|
|
96
|
-
boolean: {
|
|
97
|
-
background: string;
|
|
98
|
-
selectedBackground: string;
|
|
99
|
-
};
|
|
100
|
-
layoutMargin: number;
|
|
101
|
-
appBorderColor: string;
|
|
102
|
-
appBorderRadius: number;
|
|
103
|
-
barTextColor: string;
|
|
104
|
-
barHoverColor: string;
|
|
105
|
-
barSelectedColor: string;
|
|
106
|
-
barBg: string;
|
|
107
|
-
brand?: Brand;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
type StorybookTheme = StorybookThemeWeb;
|
|
111
|
-
declare const theme: StorybookThemeWeb;
|
|
112
|
-
declare const darkTheme: StorybookThemeWeb;
|
|
113
|
-
|
|
114
6
|
type IsPreReact19 = 2 extends Parameters<React.FunctionComponent<any>>['length']
|
|
115
7
|
? true
|
|
116
8
|
: false
|
|
@@ -495,4 +387,112 @@ interface CreateStyled extends CreateStyled$1, StyledComponents {}
|
|
|
495
387
|
|
|
496
388
|
declare const styled: CreateStyled
|
|
497
389
|
|
|
390
|
+
declare const color: {
|
|
391
|
+
primary: string;
|
|
392
|
+
secondary: string;
|
|
393
|
+
secondaryLighter: string;
|
|
394
|
+
tertiary: string;
|
|
395
|
+
ancillary: string;
|
|
396
|
+
orange: string;
|
|
397
|
+
gold: string;
|
|
398
|
+
green: string;
|
|
399
|
+
seafoam: string;
|
|
400
|
+
purple: string;
|
|
401
|
+
ultraviolet: string;
|
|
402
|
+
lightest: string;
|
|
403
|
+
lighter: string;
|
|
404
|
+
light: string;
|
|
405
|
+
mediumlight: string;
|
|
406
|
+
medium: string;
|
|
407
|
+
mediumdark: string;
|
|
408
|
+
dark: string;
|
|
409
|
+
darker: string;
|
|
410
|
+
darkest: string;
|
|
411
|
+
border: string;
|
|
412
|
+
positive: string;
|
|
413
|
+
negative: string;
|
|
414
|
+
warning: string;
|
|
415
|
+
critical: string;
|
|
416
|
+
defaultText: string;
|
|
417
|
+
inverseText: string;
|
|
418
|
+
positiveText: string;
|
|
419
|
+
negativeText: string;
|
|
420
|
+
warningText: string;
|
|
421
|
+
};
|
|
422
|
+
declare const background: {
|
|
423
|
+
app: string;
|
|
424
|
+
bar: string;
|
|
425
|
+
content: string;
|
|
426
|
+
preview: string;
|
|
427
|
+
gridCellSize: number;
|
|
428
|
+
hoverable: string;
|
|
429
|
+
positive: string;
|
|
430
|
+
negative: string;
|
|
431
|
+
warning: string;
|
|
432
|
+
critical: string;
|
|
433
|
+
};
|
|
434
|
+
declare const typography: {
|
|
435
|
+
weight: {
|
|
436
|
+
regular: TextStyle["fontWeight"];
|
|
437
|
+
bold: TextStyle["fontWeight"];
|
|
438
|
+
};
|
|
439
|
+
size: {
|
|
440
|
+
s1: number;
|
|
441
|
+
s2: number;
|
|
442
|
+
s3: number;
|
|
443
|
+
m1: number;
|
|
444
|
+
m2: number;
|
|
445
|
+
m3: number;
|
|
446
|
+
l1: number;
|
|
447
|
+
l2: number;
|
|
448
|
+
l3: number;
|
|
449
|
+
code: number;
|
|
450
|
+
};
|
|
451
|
+
};
|
|
452
|
+
type Color = typeof color;
|
|
453
|
+
type Background = typeof background;
|
|
454
|
+
type Typography = typeof typography;
|
|
455
|
+
interface Brand {
|
|
456
|
+
title?: string | undefined;
|
|
457
|
+
url?: string | null | undefined;
|
|
458
|
+
image?: ImageSourcePropType | ReactElement | null | undefined;
|
|
459
|
+
resizeMode?: ImageProps['resizeMode'] | null | undefined;
|
|
460
|
+
target?: string | null | undefined;
|
|
461
|
+
}
|
|
462
|
+
interface StorybookThemeWeb {
|
|
463
|
+
base: 'light' | 'dark';
|
|
464
|
+
color: Color;
|
|
465
|
+
background: Background;
|
|
466
|
+
typography: Typography;
|
|
467
|
+
textMutedColor: string;
|
|
468
|
+
input: {
|
|
469
|
+
border: string;
|
|
470
|
+
background: string;
|
|
471
|
+
color: string;
|
|
472
|
+
borderRadius: number;
|
|
473
|
+
paddingHorizontal: number;
|
|
474
|
+
paddingVertical: number;
|
|
475
|
+
};
|
|
476
|
+
button: {
|
|
477
|
+
background: string;
|
|
478
|
+
border: string;
|
|
479
|
+
};
|
|
480
|
+
boolean: {
|
|
481
|
+
background: string;
|
|
482
|
+
selectedBackground: string;
|
|
483
|
+
};
|
|
484
|
+
layoutMargin: number;
|
|
485
|
+
appBorderColor: string;
|
|
486
|
+
appBorderRadius: number;
|
|
487
|
+
barTextColor: string;
|
|
488
|
+
barHoverColor: string;
|
|
489
|
+
barSelectedColor: string;
|
|
490
|
+
barBg: string;
|
|
491
|
+
brand?: Brand;
|
|
492
|
+
}
|
|
493
|
+
|
|
494
|
+
type StorybookTheme = StorybookThemeWeb;
|
|
495
|
+
declare const theme: StorybookThemeWeb;
|
|
496
|
+
declare const darkTheme: StorybookThemeWeb;
|
|
497
|
+
|
|
498
498
|
export { StorybookTheme, StyledComponent, ThemeProvider, darkTheme, styled, theme, useTheme, withTheme };
|
package/dist/index.js
CHANGED
|
@@ -1436,9 +1436,9 @@ var require_css_to_react_native = __commonJS({
|
|
|
1436
1436
|
}
|
|
1437
1437
|
});
|
|
1438
1438
|
|
|
1439
|
-
// ../../node_modules/
|
|
1439
|
+
// ../../node_modules/react-is/cjs/react-is.production.min.js
|
|
1440
1440
|
var require_react_is_production_min = __commonJS({
|
|
1441
|
-
"../../node_modules/
|
|
1441
|
+
"../../node_modules/react-is/cjs/react-is.production.min.js"(exports) {
|
|
1442
1442
|
"use strict";
|
|
1443
1443
|
var b = "function" === typeof Symbol && Symbol.for;
|
|
1444
1444
|
var c = b ? Symbol.for("react.element") : 60103;
|
|
@@ -1549,9 +1549,9 @@ var require_react_is_production_min = __commonJS({
|
|
|
1549
1549
|
}
|
|
1550
1550
|
});
|
|
1551
1551
|
|
|
1552
|
-
// ../../node_modules/
|
|
1552
|
+
// ../../node_modules/react-is/cjs/react-is.development.js
|
|
1553
1553
|
var require_react_is_development = __commonJS({
|
|
1554
|
-
"../../node_modules/
|
|
1554
|
+
"../../node_modules/react-is/cjs/react-is.development.js"(exports) {
|
|
1555
1555
|
"use strict";
|
|
1556
1556
|
if (process.env.NODE_ENV !== "production") {
|
|
1557
1557
|
(function() {
|
|
@@ -1704,9 +1704,9 @@ var require_react_is_development = __commonJS({
|
|
|
1704
1704
|
}
|
|
1705
1705
|
});
|
|
1706
1706
|
|
|
1707
|
-
// ../../node_modules/
|
|
1707
|
+
// ../../node_modules/react-is/index.js
|
|
1708
1708
|
var require_react_is = __commonJS({
|
|
1709
|
-
"../../node_modules/
|
|
1709
|
+
"../../node_modules/react-is/index.js"(exports, module2) {
|
|
1710
1710
|
"use strict";
|
|
1711
1711
|
if (process.env.NODE_ENV === "production") {
|
|
1712
1712
|
module2.exports = require_react_is_production_min();
|
|
@@ -1833,315 +1833,6 @@ __export(src_exports, {
|
|
|
1833
1833
|
});
|
|
1834
1834
|
module.exports = __toCommonJS(src_exports);
|
|
1835
1835
|
|
|
1836
|
-
// src/web-theme.ts
|
|
1837
|
-
var import_polished = require("polished");
|
|
1838
|
-
var color = {
|
|
1839
|
-
// Official color palette
|
|
1840
|
-
primary: "#FF4785",
|
|
1841
|
-
// coral
|
|
1842
|
-
secondary: "#029CFD",
|
|
1843
|
-
// ocean
|
|
1844
|
-
secondaryLighter: "rgba(2, 157, 253, 0.9)",
|
|
1845
|
-
// ocean
|
|
1846
|
-
tertiary: "#FAFBFC",
|
|
1847
|
-
ancillary: "#22a699",
|
|
1848
|
-
// Complimentary
|
|
1849
|
-
orange: "#FC521F",
|
|
1850
|
-
gold: "#FFAE00",
|
|
1851
|
-
green: "#66BF3C",
|
|
1852
|
-
seafoam: "#37D5D3",
|
|
1853
|
-
purple: "#6F2CAC",
|
|
1854
|
-
ultraviolet: "#2A0481",
|
|
1855
|
-
// Monochrome
|
|
1856
|
-
lightest: "#FFFFFF",
|
|
1857
|
-
lighter: "#F7FAFC",
|
|
1858
|
-
light: "#EEF3F6",
|
|
1859
|
-
mediumlight: "#ECF4F9",
|
|
1860
|
-
medium: "#D9E8F2",
|
|
1861
|
-
mediumdark: "#73828C",
|
|
1862
|
-
dark: "#5C6870",
|
|
1863
|
-
darker: "#454E54",
|
|
1864
|
-
darkest: "#2E3438",
|
|
1865
|
-
// For borders
|
|
1866
|
-
border: "hsla(203, 50%, 30%, 0.15)",
|
|
1867
|
-
// Status
|
|
1868
|
-
positive: "#66BF3C",
|
|
1869
|
-
negative: "#FF4400",
|
|
1870
|
-
warning: "#E69D00",
|
|
1871
|
-
critical: "#FFFFFF",
|
|
1872
|
-
// Text
|
|
1873
|
-
defaultText: "#2E3438",
|
|
1874
|
-
inverseText: "#FFFFFF",
|
|
1875
|
-
positiveText: "#448028",
|
|
1876
|
-
negativeText: "#D43900",
|
|
1877
|
-
warningText: "#A15C20"
|
|
1878
|
-
};
|
|
1879
|
-
var background = {
|
|
1880
|
-
app: "#F6F9FC",
|
|
1881
|
-
bar: color.lightest,
|
|
1882
|
-
content: color.lightest,
|
|
1883
|
-
preview: color.lightest,
|
|
1884
|
-
gridCellSize: 10,
|
|
1885
|
-
hoverable: (0, import_polished.transparentize)(0.9, color.secondary),
|
|
1886
|
-
// hover state for items in a list
|
|
1887
|
-
// Notification, error, and warning backgrounds
|
|
1888
|
-
positive: "#E1FFD4",
|
|
1889
|
-
negative: "#FEDED2",
|
|
1890
|
-
warning: "#FFF5CF",
|
|
1891
|
-
critical: "#FF4400"
|
|
1892
|
-
};
|
|
1893
|
-
var light = {
|
|
1894
|
-
base: "light",
|
|
1895
|
-
// Storybook-specific color palette
|
|
1896
|
-
colorPrimary: "#FF4785",
|
|
1897
|
-
// coral
|
|
1898
|
-
colorSecondary: "#029CFD",
|
|
1899
|
-
// ocean
|
|
1900
|
-
// UI
|
|
1901
|
-
appBg: background.app,
|
|
1902
|
-
appContentBg: color.lightest,
|
|
1903
|
-
appPreviewBg: color.lightest,
|
|
1904
|
-
appBorderColor: color.border,
|
|
1905
|
-
appBorderRadius: 4,
|
|
1906
|
-
// Fonts
|
|
1907
|
-
// Text colors
|
|
1908
|
-
textColor: color.darkest,
|
|
1909
|
-
textInverseColor: color.lightest,
|
|
1910
|
-
textMutedColor: color.dark,
|
|
1911
|
-
// Toolbar default and active colors
|
|
1912
|
-
barTextColor: color.mediumdark,
|
|
1913
|
-
barHoverColor: color.secondary,
|
|
1914
|
-
barSelectedColor: color.secondary,
|
|
1915
|
-
barBg: color.lightest,
|
|
1916
|
-
// Form colors
|
|
1917
|
-
buttonBg: background.app,
|
|
1918
|
-
buttonBorder: color.medium,
|
|
1919
|
-
booleanBg: color.mediumlight,
|
|
1920
|
-
booleanSelectedBg: color.lightest,
|
|
1921
|
-
inputBg: color.lightest,
|
|
1922
|
-
inputBorder: color.border,
|
|
1923
|
-
inputTextColor: color.darkest,
|
|
1924
|
-
inputBorderRadius: 4
|
|
1925
|
-
};
|
|
1926
|
-
var dark = {
|
|
1927
|
-
base: "dark",
|
|
1928
|
-
// Storybook-specific color palette
|
|
1929
|
-
colorPrimary: "#FF4785",
|
|
1930
|
-
// coral
|
|
1931
|
-
colorSecondary: "#029CFD",
|
|
1932
|
-
// ocean
|
|
1933
|
-
// UI
|
|
1934
|
-
appBg: "#222425",
|
|
1935
|
-
appContentBg: "#1B1C1D",
|
|
1936
|
-
appPreviewBg: color.lightest,
|
|
1937
|
-
appBorderColor: "rgba(255,255,255,.1)",
|
|
1938
|
-
appBorderRadius: 4,
|
|
1939
|
-
// Text colors
|
|
1940
|
-
textColor: "#C9CDCF",
|
|
1941
|
-
textInverseColor: "#222425",
|
|
1942
|
-
textMutedColor: "#798186",
|
|
1943
|
-
// Toolbar default and active colors
|
|
1944
|
-
barTextColor: color.mediumdark,
|
|
1945
|
-
barHoverColor: color.secondary,
|
|
1946
|
-
barSelectedColor: color.secondary,
|
|
1947
|
-
barBg: "#292C2E",
|
|
1948
|
-
// Form colors
|
|
1949
|
-
buttonBg: "#222425",
|
|
1950
|
-
buttonBorder: "rgba(255,255,255,.1)",
|
|
1951
|
-
booleanBg: "#222425",
|
|
1952
|
-
booleanSelectedBg: "#2E3438",
|
|
1953
|
-
inputBg: "#1B1C1D",
|
|
1954
|
-
inputBorder: "rgba(255,255,255,.1)",
|
|
1955
|
-
inputTextColor: color.lightest,
|
|
1956
|
-
inputBorderRadius: 4
|
|
1957
|
-
};
|
|
1958
|
-
|
|
1959
|
-
// src/theme.ts
|
|
1960
|
-
var typography = {
|
|
1961
|
-
weight: {
|
|
1962
|
-
regular: "400",
|
|
1963
|
-
bold: "700"
|
|
1964
|
-
},
|
|
1965
|
-
size: {
|
|
1966
|
-
s1: 12,
|
|
1967
|
-
s2: 14,
|
|
1968
|
-
s3: 16,
|
|
1969
|
-
m1: 20,
|
|
1970
|
-
m2: 24,
|
|
1971
|
-
m3: 28,
|
|
1972
|
-
l1: 32,
|
|
1973
|
-
l2: 40,
|
|
1974
|
-
l3: 48,
|
|
1975
|
-
code: 90
|
|
1976
|
-
}
|
|
1977
|
-
};
|
|
1978
|
-
var theme = {
|
|
1979
|
-
base: "light",
|
|
1980
|
-
textMutedColor: color.dark,
|
|
1981
|
-
color: {
|
|
1982
|
-
primary: light.colorPrimary,
|
|
1983
|
-
secondary: light.colorSecondary,
|
|
1984
|
-
secondaryLighter: color.secondaryLighter,
|
|
1985
|
-
tertiary: color.tertiary,
|
|
1986
|
-
ancillary: color.ancillary,
|
|
1987
|
-
// Complimentary
|
|
1988
|
-
orange: color.orange,
|
|
1989
|
-
gold: color.gold,
|
|
1990
|
-
green: color.green,
|
|
1991
|
-
seafoam: color.seafoam,
|
|
1992
|
-
purple: color.purple,
|
|
1993
|
-
ultraviolet: color.ultraviolet,
|
|
1994
|
-
// Monochrome
|
|
1995
|
-
lightest: color.lightest,
|
|
1996
|
-
lighter: color.lighter,
|
|
1997
|
-
light: color.light,
|
|
1998
|
-
mediumlight: color.mediumlight,
|
|
1999
|
-
medium: color.medium,
|
|
2000
|
-
mediumdark: color.mediumdark,
|
|
2001
|
-
dark: color.dark,
|
|
2002
|
-
darker: color.darker,
|
|
2003
|
-
darkest: color.darkest,
|
|
2004
|
-
// For borders
|
|
2005
|
-
border: color.border,
|
|
2006
|
-
// Status
|
|
2007
|
-
positive: color.positive,
|
|
2008
|
-
negative: color.negative,
|
|
2009
|
-
warning: color.warning,
|
|
2010
|
-
critical: color.critical,
|
|
2011
|
-
defaultText: light.textColor || color.darkest,
|
|
2012
|
-
inverseText: light.textInverseColor || color.lightest,
|
|
2013
|
-
positiveText: color.positiveText,
|
|
2014
|
-
negativeText: color.negativeText,
|
|
2015
|
-
warningText: color.warningText
|
|
2016
|
-
},
|
|
2017
|
-
background: {
|
|
2018
|
-
app: light.appBg,
|
|
2019
|
-
bar: light.barBg,
|
|
2020
|
-
content: light.appContentBg,
|
|
2021
|
-
preview: light.appPreviewBg,
|
|
2022
|
-
gridCellSize: light.gridCellSize || background.gridCellSize,
|
|
2023
|
-
hoverable: background.hoverable,
|
|
2024
|
-
positive: background.positive,
|
|
2025
|
-
negative: background.negative,
|
|
2026
|
-
warning: background.warning,
|
|
2027
|
-
critical: background.critical
|
|
2028
|
-
},
|
|
2029
|
-
typography: {
|
|
2030
|
-
weight: typography.weight,
|
|
2031
|
-
size: typography.size
|
|
2032
|
-
},
|
|
2033
|
-
input: {
|
|
2034
|
-
background: light.inputBg,
|
|
2035
|
-
border: light.inputBorder,
|
|
2036
|
-
borderRadius: light.inputBorderRadius,
|
|
2037
|
-
color: light.inputTextColor,
|
|
2038
|
-
paddingHorizontal: 10,
|
|
2039
|
-
paddingVertical: 6
|
|
2040
|
-
},
|
|
2041
|
-
button: {
|
|
2042
|
-
background: light.buttonBg || light.inputBg,
|
|
2043
|
-
border: light.buttonBorder || light.inputBorder
|
|
2044
|
-
},
|
|
2045
|
-
boolean: {
|
|
2046
|
-
background: light.booleanBg || light.inputBorder,
|
|
2047
|
-
selectedBackground: light.booleanSelectedBg || light.inputBg
|
|
2048
|
-
},
|
|
2049
|
-
// UI
|
|
2050
|
-
layoutMargin: 10,
|
|
2051
|
-
appBorderColor: light.appBorderColor,
|
|
2052
|
-
appBorderRadius: light.appBorderRadius,
|
|
2053
|
-
// Toolbar default/active colors
|
|
2054
|
-
barTextColor: light.barTextColor,
|
|
2055
|
-
barHoverColor: light.barHoverColor || light.colorSecondary,
|
|
2056
|
-
barSelectedColor: light.barSelectedColor || light.colorSecondary,
|
|
2057
|
-
barBg: light.barBg,
|
|
2058
|
-
// Brand logo/text
|
|
2059
|
-
brand: void 0
|
|
2060
|
-
};
|
|
2061
|
-
var darkTheme = {
|
|
2062
|
-
base: "dark",
|
|
2063
|
-
textMutedColor: "#798186",
|
|
2064
|
-
color: {
|
|
2065
|
-
primary: dark.colorPrimary,
|
|
2066
|
-
secondary: dark.colorSecondary,
|
|
2067
|
-
secondaryLighter: color.secondaryLighter,
|
|
2068
|
-
tertiary: color.tertiary,
|
|
2069
|
-
ancillary: color.ancillary,
|
|
2070
|
-
// Complimentary
|
|
2071
|
-
orange: color.orange,
|
|
2072
|
-
gold: color.gold,
|
|
2073
|
-
green: color.green,
|
|
2074
|
-
seafoam: color.seafoam,
|
|
2075
|
-
purple: color.purple,
|
|
2076
|
-
ultraviolet: color.ultraviolet,
|
|
2077
|
-
// Monochrome
|
|
2078
|
-
lightest: color.lightest,
|
|
2079
|
-
lighter: color.lighter,
|
|
2080
|
-
light: color.light,
|
|
2081
|
-
mediumlight: color.mediumlight,
|
|
2082
|
-
medium: color.medium,
|
|
2083
|
-
mediumdark: color.mediumdark,
|
|
2084
|
-
dark: color.dark,
|
|
2085
|
-
darker: color.darker,
|
|
2086
|
-
darkest: color.darkest,
|
|
2087
|
-
// For borders
|
|
2088
|
-
border: color.border,
|
|
2089
|
-
// Status
|
|
2090
|
-
positive: color.positive,
|
|
2091
|
-
negative: color.negative,
|
|
2092
|
-
warning: color.warning,
|
|
2093
|
-
critical: color.critical,
|
|
2094
|
-
defaultText: dark.textColor || color.darkest,
|
|
2095
|
-
inverseText: dark.textInverseColor || color.lightest,
|
|
2096
|
-
positiveText: color.positiveText,
|
|
2097
|
-
negativeText: color.negativeText,
|
|
2098
|
-
warningText: color.warningText
|
|
2099
|
-
},
|
|
2100
|
-
background: {
|
|
2101
|
-
app: dark.appBg,
|
|
2102
|
-
bar: dark.barBg,
|
|
2103
|
-
content: dark.appContentBg,
|
|
2104
|
-
preview: dark.appPreviewBg,
|
|
2105
|
-
gridCellSize: dark.gridCellSize || background.gridCellSize,
|
|
2106
|
-
hoverable: background.hoverable,
|
|
2107
|
-
positive: background.positive,
|
|
2108
|
-
negative: background.negative,
|
|
2109
|
-
warning: background.warning,
|
|
2110
|
-
critical: background.critical
|
|
2111
|
-
},
|
|
2112
|
-
typography: {
|
|
2113
|
-
weight: typography.weight,
|
|
2114
|
-
size: typography.size
|
|
2115
|
-
},
|
|
2116
|
-
input: {
|
|
2117
|
-
background: dark.inputBg,
|
|
2118
|
-
border: dark.inputBorder,
|
|
2119
|
-
borderRadius: dark.inputBorderRadius,
|
|
2120
|
-
color: dark.inputTextColor,
|
|
2121
|
-
paddingHorizontal: 10,
|
|
2122
|
-
paddingVertical: 6
|
|
2123
|
-
},
|
|
2124
|
-
button: {
|
|
2125
|
-
background: dark.buttonBg || dark.inputBg,
|
|
2126
|
-
border: dark.buttonBorder || dark.inputBorder
|
|
2127
|
-
},
|
|
2128
|
-
boolean: {
|
|
2129
|
-
background: dark.booleanBg || dark.inputBorder,
|
|
2130
|
-
selectedBackground: dark.booleanSelectedBg || dark.inputBg
|
|
2131
|
-
},
|
|
2132
|
-
// UI
|
|
2133
|
-
layoutMargin: 10,
|
|
2134
|
-
appBorderColor: dark.appBorderColor,
|
|
2135
|
-
appBorderRadius: dark.appBorderRadius,
|
|
2136
|
-
// Toolbar default/active colors
|
|
2137
|
-
barTextColor: dark.barTextColor,
|
|
2138
|
-
barHoverColor: dark.barHoverColor || dark.colorSecondary,
|
|
2139
|
-
barSelectedColor: dark.barSelectedColor || dark.colorSecondary,
|
|
2140
|
-
barBg: dark.barBg,
|
|
2141
|
-
// Brand logo/text
|
|
2142
|
-
brand: void 0
|
|
2143
|
-
};
|
|
2144
|
-
|
|
2145
1836
|
// ../../node_modules/@emotion/native/dist/emotion-native.esm.js
|
|
2146
1837
|
var reactNative = __toESM(require("react-native"));
|
|
2147
1838
|
var import_react_native = require("react-native");
|
|
@@ -3176,82 +2867,391 @@ function convertStyles(str) {
|
|
|
3176
2867
|
console.error(errorMsg);
|
|
3177
2868
|
}
|
|
3178
2869
|
}
|
|
3179
|
-
}
|
|
3180
|
-
var testOmitPropsOnComponent = function testOmitPropsOnComponent2(prop) {
|
|
3181
|
-
return prop !== "theme" && prop !== "as";
|
|
2870
|
+
}
|
|
2871
|
+
var testOmitPropsOnComponent = function testOmitPropsOnComponent2(prop) {
|
|
2872
|
+
return prop !== "theme" && prop !== "as";
|
|
2873
|
+
};
|
|
2874
|
+
function createStyled(StyleSheet4, options) {
|
|
2875
|
+
var _options$getShouldFor;
|
|
2876
|
+
var getShouldForwardProp = (_options$getShouldFor = options == null ? void 0 : options.getShouldForwardProp) != null ? _options$getShouldFor : function() {
|
|
2877
|
+
return testOmitPropsOnComponent;
|
|
2878
|
+
};
|
|
2879
|
+
var css2 = createCss(StyleSheet4);
|
|
2880
|
+
return function createEmotion(component, options2) {
|
|
2881
|
+
var shouldForwardProp = options2 && options2.shouldForwardProp ? options2.shouldForwardProp : void 0;
|
|
2882
|
+
var defaultShouldForwardProp = shouldForwardProp || getShouldForwardProp(component);
|
|
2883
|
+
var shouldUseAs = !defaultShouldForwardProp("as");
|
|
2884
|
+
return function createStyledComponent() {
|
|
2885
|
+
var styles2;
|
|
2886
|
+
for (var _len = arguments.length, rawStyles = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
2887
|
+
rawStyles[_key] = arguments[_key];
|
|
2888
|
+
}
|
|
2889
|
+
if (rawStyles[0] == null || rawStyles[0].raw === void 0) {
|
|
2890
|
+
styles2 = rawStyles;
|
|
2891
|
+
} else {
|
|
2892
|
+
styles2 = interleave(rawStyles);
|
|
2893
|
+
}
|
|
2894
|
+
var Styled = /* @__PURE__ */ React4.forwardRef(function(props, ref) {
|
|
2895
|
+
var finalTag = shouldUseAs && props.as || component;
|
|
2896
|
+
var mergedProps = props;
|
|
2897
|
+
if (props.theme == null) {
|
|
2898
|
+
mergedProps = {};
|
|
2899
|
+
for (var key in props) {
|
|
2900
|
+
mergedProps[key] = props[key];
|
|
2901
|
+
}
|
|
2902
|
+
mergedProps.theme = React4.useContext(ThemeContext);
|
|
2903
|
+
}
|
|
2904
|
+
var finalShouldForwardProp = shouldUseAs && shouldForwardProp === void 0 ? getShouldForwardProp(finalTag) : defaultShouldForwardProp;
|
|
2905
|
+
var newProps = {};
|
|
2906
|
+
for (var _key2 in props) {
|
|
2907
|
+
if (shouldUseAs && _key2 === "as")
|
|
2908
|
+
continue;
|
|
2909
|
+
if (finalShouldForwardProp(_key2)) {
|
|
2910
|
+
newProps[_key2] = props[_key2];
|
|
2911
|
+
}
|
|
2912
|
+
}
|
|
2913
|
+
newProps.style = [css2.apply(mergedProps, styles2), props.style];
|
|
2914
|
+
if (ref) {
|
|
2915
|
+
newProps.ref = ref;
|
|
2916
|
+
}
|
|
2917
|
+
return /* @__PURE__ */ React4.createElement(finalTag, newProps);
|
|
2918
|
+
});
|
|
2919
|
+
Styled.displayName = "emotion(" + getDisplayName(component) + ")";
|
|
2920
|
+
var withComponent = function withComponent2(newComponent) {
|
|
2921
|
+
return createEmotion(newComponent).apply(void 0, styles2);
|
|
2922
|
+
};
|
|
2923
|
+
var castedStyled = Styled;
|
|
2924
|
+
castedStyled.withComponent = withComponent;
|
|
2925
|
+
return castedStyled;
|
|
2926
|
+
};
|
|
2927
|
+
};
|
|
2928
|
+
}
|
|
2929
|
+
var getDisplayName = function getDisplayName2(primitive) {
|
|
2930
|
+
return typeof primitive === "string" ? primitive : primitive.displayName || primitive.name || "Styled";
|
|
2931
|
+
};
|
|
2932
|
+
|
|
2933
|
+
// ../../node_modules/@emotion/native/dist/emotion-native.esm.js
|
|
2934
|
+
var styled = createStyled(import_react_native.StyleSheet);
|
|
2935
|
+
var css = createCss(reactNative.StyleSheet);
|
|
2936
|
+
var components = ["ActivityIndicator", "Button", "DatePickerIOS", "DrawerLayoutAndroid", "FlatList", "Image", "ImageBackground", "KeyboardAvoidingView", "ListView", "Modal", "NavigatorIOS", "Picker", "PickerIOS", "Pressable", "ProgressBarAndroid", "ProgressViewIOS", "RecyclerViewBackedScrollView", "RefreshControl", "SafeAreaView", "ScrollView", "SectionList", "SegmentedControlIOS", "Slider", "SnapshotViewIOS", "StatusBar", "SwipeableListView", "Switch", "SwitchIOS", "TabBarIOS", "Text", "TextInput", "ToolbarAndroid", "TouchableHighlight", "TouchableNativeFeedback", "TouchableOpacity", "TouchableWithoutFeedback", "View", "ViewPagerAndroid"];
|
|
2937
|
+
var index = components.reduce(function(acc, comp) {
|
|
2938
|
+
return Object.defineProperty(acc, comp, {
|
|
2939
|
+
enumerable: true,
|
|
2940
|
+
configurable: false,
|
|
2941
|
+
get: function get() {
|
|
2942
|
+
return styled(reactNative[comp]);
|
|
2943
|
+
}
|
|
2944
|
+
});
|
|
2945
|
+
}, styled);
|
|
2946
|
+
|
|
2947
|
+
// src/web-theme.ts
|
|
2948
|
+
var import_polished = require("polished");
|
|
2949
|
+
var color = {
|
|
2950
|
+
// Official color palette
|
|
2951
|
+
primary: "#FF4785",
|
|
2952
|
+
// coral
|
|
2953
|
+
secondary: "#029CFD",
|
|
2954
|
+
// ocean
|
|
2955
|
+
secondaryLighter: "rgba(2, 157, 253, 0.9)",
|
|
2956
|
+
// ocean
|
|
2957
|
+
tertiary: "#FAFBFC",
|
|
2958
|
+
ancillary: "#22a699",
|
|
2959
|
+
// Complimentary
|
|
2960
|
+
orange: "#FC521F",
|
|
2961
|
+
gold: "#FFAE00",
|
|
2962
|
+
green: "#66BF3C",
|
|
2963
|
+
seafoam: "#37D5D3",
|
|
2964
|
+
purple: "#6F2CAC",
|
|
2965
|
+
ultraviolet: "#2A0481",
|
|
2966
|
+
// Monochrome
|
|
2967
|
+
lightest: "#FFFFFF",
|
|
2968
|
+
lighter: "#F7FAFC",
|
|
2969
|
+
light: "#EEF3F6",
|
|
2970
|
+
mediumlight: "#ECF4F9",
|
|
2971
|
+
medium: "#D9E8F2",
|
|
2972
|
+
mediumdark: "#73828C",
|
|
2973
|
+
dark: "#5C6870",
|
|
2974
|
+
darker: "#454E54",
|
|
2975
|
+
darkest: "#2E3438",
|
|
2976
|
+
// For borders
|
|
2977
|
+
border: "hsla(203, 50%, 30%, 0.15)",
|
|
2978
|
+
// Status
|
|
2979
|
+
positive: "#66BF3C",
|
|
2980
|
+
negative: "#FF4400",
|
|
2981
|
+
warning: "#E69D00",
|
|
2982
|
+
critical: "#FFFFFF",
|
|
2983
|
+
// Text
|
|
2984
|
+
defaultText: "#2E3438",
|
|
2985
|
+
inverseText: "#FFFFFF",
|
|
2986
|
+
positiveText: "#448028",
|
|
2987
|
+
negativeText: "#D43900",
|
|
2988
|
+
warningText: "#A15C20"
|
|
2989
|
+
};
|
|
2990
|
+
var background = {
|
|
2991
|
+
app: "#F6F9FC",
|
|
2992
|
+
bar: color.lightest,
|
|
2993
|
+
content: color.lightest,
|
|
2994
|
+
preview: color.lightest,
|
|
2995
|
+
gridCellSize: 10,
|
|
2996
|
+
hoverable: (0, import_polished.transparentize)(0.9, color.secondary),
|
|
2997
|
+
// hover state for items in a list
|
|
2998
|
+
// Notification, error, and warning backgrounds
|
|
2999
|
+
positive: "#E1FFD4",
|
|
3000
|
+
negative: "#FEDED2",
|
|
3001
|
+
warning: "#FFF5CF",
|
|
3002
|
+
critical: "#FF4400"
|
|
3003
|
+
};
|
|
3004
|
+
var light = {
|
|
3005
|
+
base: "light",
|
|
3006
|
+
// Storybook-specific color palette
|
|
3007
|
+
colorPrimary: "#FF4785",
|
|
3008
|
+
// coral
|
|
3009
|
+
colorSecondary: "#029CFD",
|
|
3010
|
+
// ocean
|
|
3011
|
+
// UI
|
|
3012
|
+
appBg: background.app,
|
|
3013
|
+
appContentBg: color.lightest,
|
|
3014
|
+
appPreviewBg: color.lightest,
|
|
3015
|
+
appBorderColor: color.border,
|
|
3016
|
+
appBorderRadius: 4,
|
|
3017
|
+
// Fonts
|
|
3018
|
+
// Text colors
|
|
3019
|
+
textColor: color.darkest,
|
|
3020
|
+
textInverseColor: color.lightest,
|
|
3021
|
+
textMutedColor: color.dark,
|
|
3022
|
+
// Toolbar default and active colors
|
|
3023
|
+
barTextColor: color.mediumdark,
|
|
3024
|
+
barHoverColor: color.secondary,
|
|
3025
|
+
barSelectedColor: color.secondary,
|
|
3026
|
+
barBg: color.lightest,
|
|
3027
|
+
// Form colors
|
|
3028
|
+
buttonBg: background.app,
|
|
3029
|
+
buttonBorder: color.medium,
|
|
3030
|
+
booleanBg: color.mediumlight,
|
|
3031
|
+
booleanSelectedBg: color.lightest,
|
|
3032
|
+
inputBg: color.lightest,
|
|
3033
|
+
inputBorder: color.border,
|
|
3034
|
+
inputTextColor: color.darkest,
|
|
3035
|
+
inputBorderRadius: 4
|
|
3036
|
+
};
|
|
3037
|
+
var dark = {
|
|
3038
|
+
base: "dark",
|
|
3039
|
+
// Storybook-specific color palette
|
|
3040
|
+
colorPrimary: "#FF4785",
|
|
3041
|
+
// coral
|
|
3042
|
+
colorSecondary: "#029CFD",
|
|
3043
|
+
// ocean
|
|
3044
|
+
// UI
|
|
3045
|
+
appBg: "#222425",
|
|
3046
|
+
appContentBg: "#1B1C1D",
|
|
3047
|
+
appPreviewBg: color.lightest,
|
|
3048
|
+
appBorderColor: "rgba(255,255,255,.1)",
|
|
3049
|
+
appBorderRadius: 4,
|
|
3050
|
+
// Text colors
|
|
3051
|
+
textColor: "#C9CDCF",
|
|
3052
|
+
textInverseColor: "#222425",
|
|
3053
|
+
textMutedColor: "#798186",
|
|
3054
|
+
// Toolbar default and active colors
|
|
3055
|
+
barTextColor: color.mediumdark,
|
|
3056
|
+
barHoverColor: color.secondary,
|
|
3057
|
+
barSelectedColor: color.secondary,
|
|
3058
|
+
barBg: "#292C2E",
|
|
3059
|
+
// Form colors
|
|
3060
|
+
buttonBg: "#222425",
|
|
3061
|
+
buttonBorder: "rgba(255,255,255,.1)",
|
|
3062
|
+
booleanBg: "#222425",
|
|
3063
|
+
booleanSelectedBg: "#2E3438",
|
|
3064
|
+
inputBg: "#1B1C1D",
|
|
3065
|
+
inputBorder: "rgba(255,255,255,.1)",
|
|
3066
|
+
inputTextColor: color.lightest,
|
|
3067
|
+
inputBorderRadius: 4
|
|
3068
|
+
};
|
|
3069
|
+
|
|
3070
|
+
// src/theme.ts
|
|
3071
|
+
var typography = {
|
|
3072
|
+
weight: {
|
|
3073
|
+
regular: "400",
|
|
3074
|
+
bold: "700"
|
|
3075
|
+
},
|
|
3076
|
+
size: {
|
|
3077
|
+
s1: 12,
|
|
3078
|
+
s2: 14,
|
|
3079
|
+
s3: 16,
|
|
3080
|
+
m1: 20,
|
|
3081
|
+
m2: 24,
|
|
3082
|
+
m3: 28,
|
|
3083
|
+
l1: 32,
|
|
3084
|
+
l2: 40,
|
|
3085
|
+
l3: 48,
|
|
3086
|
+
code: 90
|
|
3087
|
+
}
|
|
3182
3088
|
};
|
|
3183
|
-
|
|
3184
|
-
|
|
3185
|
-
|
|
3186
|
-
|
|
3187
|
-
|
|
3188
|
-
|
|
3189
|
-
|
|
3190
|
-
|
|
3191
|
-
|
|
3192
|
-
|
|
3193
|
-
|
|
3194
|
-
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
|
|
3206
|
-
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
|
-
|
|
3210
|
-
|
|
3211
|
-
|
|
3212
|
-
|
|
3213
|
-
|
|
3214
|
-
|
|
3215
|
-
|
|
3216
|
-
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
|
|
3221
|
-
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
|
|
3237
|
-
}
|
|
3238
|
-
|
|
3239
|
-
|
|
3089
|
+
var theme = {
|
|
3090
|
+
base: "light",
|
|
3091
|
+
textMutedColor: color.dark,
|
|
3092
|
+
color: {
|
|
3093
|
+
primary: light.colorPrimary,
|
|
3094
|
+
secondary: light.colorSecondary,
|
|
3095
|
+
secondaryLighter: color.secondaryLighter,
|
|
3096
|
+
tertiary: color.tertiary,
|
|
3097
|
+
ancillary: color.ancillary,
|
|
3098
|
+
// Complimentary
|
|
3099
|
+
orange: color.orange,
|
|
3100
|
+
gold: color.gold,
|
|
3101
|
+
green: color.green,
|
|
3102
|
+
seafoam: color.seafoam,
|
|
3103
|
+
purple: color.purple,
|
|
3104
|
+
ultraviolet: color.ultraviolet,
|
|
3105
|
+
// Monochrome
|
|
3106
|
+
lightest: color.lightest,
|
|
3107
|
+
lighter: color.lighter,
|
|
3108
|
+
light: color.light,
|
|
3109
|
+
mediumlight: color.mediumlight,
|
|
3110
|
+
medium: color.medium,
|
|
3111
|
+
mediumdark: color.mediumdark,
|
|
3112
|
+
dark: color.dark,
|
|
3113
|
+
darker: color.darker,
|
|
3114
|
+
darkest: color.darkest,
|
|
3115
|
+
// For borders
|
|
3116
|
+
border: color.border,
|
|
3117
|
+
// Status
|
|
3118
|
+
positive: color.positive,
|
|
3119
|
+
negative: color.negative,
|
|
3120
|
+
warning: color.warning,
|
|
3121
|
+
critical: color.critical,
|
|
3122
|
+
defaultText: light.textColor || color.darkest,
|
|
3123
|
+
inverseText: light.textInverseColor || color.lightest,
|
|
3124
|
+
positiveText: color.positiveText,
|
|
3125
|
+
negativeText: color.negativeText,
|
|
3126
|
+
warningText: color.warningText
|
|
3127
|
+
},
|
|
3128
|
+
background: {
|
|
3129
|
+
app: light.appBg,
|
|
3130
|
+
bar: light.barBg,
|
|
3131
|
+
content: light.appContentBg,
|
|
3132
|
+
preview: light.appPreviewBg,
|
|
3133
|
+
gridCellSize: light.gridCellSize || background.gridCellSize,
|
|
3134
|
+
hoverable: background.hoverable,
|
|
3135
|
+
positive: background.positive,
|
|
3136
|
+
negative: background.negative,
|
|
3137
|
+
warning: background.warning,
|
|
3138
|
+
critical: background.critical
|
|
3139
|
+
},
|
|
3140
|
+
typography: {
|
|
3141
|
+
weight: typography.weight,
|
|
3142
|
+
size: typography.size
|
|
3143
|
+
},
|
|
3144
|
+
input: {
|
|
3145
|
+
background: light.inputBg,
|
|
3146
|
+
border: light.inputBorder,
|
|
3147
|
+
borderRadius: light.inputBorderRadius,
|
|
3148
|
+
color: light.inputTextColor,
|
|
3149
|
+
paddingHorizontal: 10,
|
|
3150
|
+
paddingVertical: 6
|
|
3151
|
+
},
|
|
3152
|
+
button: {
|
|
3153
|
+
background: light.buttonBg || light.inputBg,
|
|
3154
|
+
border: light.buttonBorder || light.inputBorder
|
|
3155
|
+
},
|
|
3156
|
+
boolean: {
|
|
3157
|
+
background: light.booleanBg || light.inputBorder,
|
|
3158
|
+
selectedBackground: light.booleanSelectedBg || light.inputBg
|
|
3159
|
+
},
|
|
3160
|
+
// UI
|
|
3161
|
+
layoutMargin: 10,
|
|
3162
|
+
appBorderColor: light.appBorderColor,
|
|
3163
|
+
appBorderRadius: light.appBorderRadius,
|
|
3164
|
+
// Toolbar default/active colors
|
|
3165
|
+
barTextColor: light.barTextColor,
|
|
3166
|
+
barHoverColor: light.barHoverColor || light.colorSecondary,
|
|
3167
|
+
barSelectedColor: light.barSelectedColor || light.colorSecondary,
|
|
3168
|
+
barBg: light.barBg,
|
|
3169
|
+
// Brand logo/text
|
|
3170
|
+
brand: void 0
|
|
3171
|
+
};
|
|
3172
|
+
var darkTheme = {
|
|
3173
|
+
base: "dark",
|
|
3174
|
+
textMutedColor: "#798186",
|
|
3175
|
+
color: {
|
|
3176
|
+
primary: dark.colorPrimary,
|
|
3177
|
+
secondary: dark.colorSecondary,
|
|
3178
|
+
secondaryLighter: color.secondaryLighter,
|
|
3179
|
+
tertiary: color.tertiary,
|
|
3180
|
+
ancillary: color.ancillary,
|
|
3181
|
+
// Complimentary
|
|
3182
|
+
orange: color.orange,
|
|
3183
|
+
gold: color.gold,
|
|
3184
|
+
green: color.green,
|
|
3185
|
+
seafoam: color.seafoam,
|
|
3186
|
+
purple: color.purple,
|
|
3187
|
+
ultraviolet: color.ultraviolet,
|
|
3188
|
+
// Monochrome
|
|
3189
|
+
lightest: color.lightest,
|
|
3190
|
+
lighter: color.lighter,
|
|
3191
|
+
light: color.light,
|
|
3192
|
+
mediumlight: color.mediumlight,
|
|
3193
|
+
medium: color.medium,
|
|
3194
|
+
mediumdark: color.mediumdark,
|
|
3195
|
+
dark: color.dark,
|
|
3196
|
+
darker: color.darker,
|
|
3197
|
+
darkest: color.darkest,
|
|
3198
|
+
// For borders
|
|
3199
|
+
border: color.border,
|
|
3200
|
+
// Status
|
|
3201
|
+
positive: color.positive,
|
|
3202
|
+
negative: color.negative,
|
|
3203
|
+
warning: color.warning,
|
|
3204
|
+
critical: color.critical,
|
|
3205
|
+
defaultText: dark.textColor || color.darkest,
|
|
3206
|
+
inverseText: dark.textInverseColor || color.lightest,
|
|
3207
|
+
positiveText: color.positiveText,
|
|
3208
|
+
negativeText: color.negativeText,
|
|
3209
|
+
warningText: color.warningText
|
|
3210
|
+
},
|
|
3211
|
+
background: {
|
|
3212
|
+
app: dark.appBg,
|
|
3213
|
+
bar: dark.barBg,
|
|
3214
|
+
content: dark.appContentBg,
|
|
3215
|
+
preview: dark.appPreviewBg,
|
|
3216
|
+
gridCellSize: dark.gridCellSize || background.gridCellSize,
|
|
3217
|
+
hoverable: background.hoverable,
|
|
3218
|
+
positive: background.positive,
|
|
3219
|
+
negative: background.negative,
|
|
3220
|
+
warning: background.warning,
|
|
3221
|
+
critical: background.critical
|
|
3222
|
+
},
|
|
3223
|
+
typography: {
|
|
3224
|
+
weight: typography.weight,
|
|
3225
|
+
size: typography.size
|
|
3226
|
+
},
|
|
3227
|
+
input: {
|
|
3228
|
+
background: dark.inputBg,
|
|
3229
|
+
border: dark.inputBorder,
|
|
3230
|
+
borderRadius: dark.inputBorderRadius,
|
|
3231
|
+
color: dark.inputTextColor,
|
|
3232
|
+
paddingHorizontal: 10,
|
|
3233
|
+
paddingVertical: 6
|
|
3234
|
+
},
|
|
3235
|
+
button: {
|
|
3236
|
+
background: dark.buttonBg || dark.inputBg,
|
|
3237
|
+
border: dark.buttonBorder || dark.inputBorder
|
|
3238
|
+
},
|
|
3239
|
+
boolean: {
|
|
3240
|
+
background: dark.booleanBg || dark.inputBorder,
|
|
3241
|
+
selectedBackground: dark.booleanSelectedBg || dark.inputBg
|
|
3242
|
+
},
|
|
3243
|
+
// UI
|
|
3244
|
+
layoutMargin: 10,
|
|
3245
|
+
appBorderColor: dark.appBorderColor,
|
|
3246
|
+
appBorderRadius: dark.appBorderRadius,
|
|
3247
|
+
// Toolbar default/active colors
|
|
3248
|
+
barTextColor: dark.barTextColor,
|
|
3249
|
+
barHoverColor: dark.barHoverColor || dark.colorSecondary,
|
|
3250
|
+
barSelectedColor: dark.barSelectedColor || dark.colorSecondary,
|
|
3251
|
+
barBg: dark.barBg,
|
|
3252
|
+
// Brand logo/text
|
|
3253
|
+
brand: void 0
|
|
3240
3254
|
};
|
|
3241
|
-
|
|
3242
|
-
// ../../node_modules/@emotion/native/dist/emotion-native.esm.js
|
|
3243
|
-
var styled = createStyled(import_react_native.StyleSheet);
|
|
3244
|
-
var css = createCss(reactNative.StyleSheet);
|
|
3245
|
-
var components = ["ActivityIndicator", "Button", "DatePickerIOS", "DrawerLayoutAndroid", "FlatList", "Image", "ImageBackground", "KeyboardAvoidingView", "ListView", "Modal", "NavigatorIOS", "Picker", "PickerIOS", "Pressable", "ProgressBarAndroid", "ProgressViewIOS", "RecyclerViewBackedScrollView", "RefreshControl", "SafeAreaView", "ScrollView", "SectionList", "SegmentedControlIOS", "Slider", "SnapshotViewIOS", "StatusBar", "SwipeableListView", "Switch", "SwitchIOS", "TabBarIOS", "Text", "TextInput", "ToolbarAndroid", "TouchableHighlight", "TouchableNativeFeedback", "TouchableOpacity", "TouchableWithoutFeedback", "View", "ViewPagerAndroid"];
|
|
3246
|
-
var index = components.reduce(function(acc, comp) {
|
|
3247
|
-
return Object.defineProperty(acc, comp, {
|
|
3248
|
-
enumerable: true,
|
|
3249
|
-
configurable: false,
|
|
3250
|
-
get: function get() {
|
|
3251
|
-
return styled(reactNative[comp]);
|
|
3252
|
-
}
|
|
3253
|
-
});
|
|
3254
|
-
}, styled);
|
|
3255
3255
|
// Annotate the CommonJS export names for ESM import in node:
|
|
3256
3256
|
0 && (module.exports = {
|
|
3257
3257
|
ThemeProvider,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/react-native-theming",
|
|
3
|
-
"version": "9.0.0-
|
|
3
|
+
"version": "9.0.0-beta.10",
|
|
4
4
|
"description": "A wrapper library around emotion 11 to provide theming support for react-native storybook",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"dist/**/*",
|
|
44
44
|
"README.md"
|
|
45
45
|
],
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "bce7f35509d03e5a5efabb8862e993ea98e201d6"
|
|
47
47
|
}
|