@hero-design/rn 8.65.1 → 8.67.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.
- package/.turbo/turbo-build.log +3 -3
- package/CHANGELOG.md +17 -0
- package/es/index.js +151 -133
- package/lib/index.js +152 -133
- package/package.json +2 -2
- package/src/components/Card/StyledCard.tsx +7 -1
- package/src/components/Card/__tests__/__snapshots__/index.spec.tsx.snap +64 -0
- package/src/components/Card/__tests__/index.spec.tsx +1 -0
- package/src/components/Card/index.tsx +7 -1
- package/src/index.ts +2 -0
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +1 -0
- package/src/theme/components/card.ts +1 -0
- package/src/theme/global/colors/__tests__/__snapshots__/swagLight.spec.ts.snap +48 -0
- package/src/theme/global/colors/__tests__/swagLight.spec.ts +7 -0
- package/src/theme/global/colors/swagLight.ts +25 -0
- package/src/theme/global/index.ts +2 -0
- package/src/theme/index.ts +2 -0
- package/stats/8.66.0/rn-stats.html +4842 -0
- package/stats/8.67.0/rn-stats.html +4844 -0
- package/types/components/Card/StyledCard.d.ts +1 -1
- package/types/components/Card/index.d.ts +1 -1
- package/types/index.d.ts +2 -2
- package/types/theme/components/card.d.ts +1 -0
- package/types/theme/global/colors/swagLight.d.ts +3 -0
- package/types/theme/global/index.d.ts +2 -1
- package/types/theme/index.d.ts +2 -2
package/lib/index.js
CHANGED
|
@@ -1403,9 +1403,9 @@ var blue$1 = colorScales.blue,
|
|
|
1403
1403
|
purple$1 = colorScales.purple,
|
|
1404
1404
|
vermilion$2 = colorScales.vermilion,
|
|
1405
1405
|
smalt = colorScales.smalt,
|
|
1406
|
-
violet$
|
|
1406
|
+
violet$2 = colorScales.violet,
|
|
1407
1407
|
yellow$1 = colorScales.yellow;
|
|
1408
|
-
var palette$
|
|
1408
|
+
var palette$c = {
|
|
1409
1409
|
black: '#000000',
|
|
1410
1410
|
white: '#ffffff',
|
|
1411
1411
|
blue: blue$1.base,
|
|
@@ -1508,19 +1508,19 @@ var palette$b = {
|
|
|
1508
1508
|
smaltLight45: smalt.lighten45,
|
|
1509
1509
|
smaltLight75: smalt.lighten75,
|
|
1510
1510
|
smaltLight90: smalt.lighten90,
|
|
1511
|
-
violet: violet$
|
|
1512
|
-
violetDark15: violet$
|
|
1513
|
-
violetDark30: violet$
|
|
1514
|
-
violetDark45: violet$
|
|
1515
|
-
violetDark60: violet$
|
|
1516
|
-
violetDark75: violet$
|
|
1517
|
-
violetDark90: violet$
|
|
1518
|
-
violetLight15: violet$
|
|
1519
|
-
violetLight30: violet$
|
|
1520
|
-
violetLight45: violet$
|
|
1521
|
-
violetLight60: violet$
|
|
1522
|
-
violetLight75: violet$
|
|
1523
|
-
violetLight90: violet$
|
|
1511
|
+
violet: violet$2.base,
|
|
1512
|
+
violetDark15: violet$2.darken15,
|
|
1513
|
+
violetDark30: violet$2.darken30,
|
|
1514
|
+
violetDark45: violet$2.darken45,
|
|
1515
|
+
violetDark60: violet$2.darken60,
|
|
1516
|
+
violetDark75: violet$2.darken75,
|
|
1517
|
+
violetDark90: violet$2.darken90,
|
|
1518
|
+
violetLight15: violet$2.lighten15,
|
|
1519
|
+
violetLight30: violet$2.lighten30,
|
|
1520
|
+
violetLight45: violet$2.lighten45,
|
|
1521
|
+
violetLight60: violet$2.lighten60,
|
|
1522
|
+
violetLight75: violet$2.lighten75,
|
|
1523
|
+
violetLight90: violet$2.lighten90,
|
|
1524
1524
|
yellow: yellow$1.base,
|
|
1525
1525
|
yellowDark15: yellow$1.darken15,
|
|
1526
1526
|
yellowDark30: yellow$1.darken30,
|
|
@@ -1533,16 +1533,16 @@ var palette$b = {
|
|
|
1533
1533
|
yellowLight90: yellow$1.lighten90
|
|
1534
1534
|
};
|
|
1535
1535
|
var mauve$3 = colorScales.mauve,
|
|
1536
|
-
violet$
|
|
1537
|
-
Object.assign(Object.assign({}, palette$
|
|
1536
|
+
violet$1 = colorScales.violet;
|
|
1537
|
+
Object.assign(Object.assign({}, palette$c), {
|
|
1538
1538
|
mauve: mauve$3.base,
|
|
1539
1539
|
mauveLight80: mauve$3.lighten80,
|
|
1540
|
-
violetDark50: violet$
|
|
1540
|
+
violetDark50: violet$1.darken50
|
|
1541
1541
|
});
|
|
1542
1542
|
var apple$3 = colorScales.apple,
|
|
1543
1543
|
hitPink$1 = colorScales.hitPink,
|
|
1544
1544
|
maasstrichtBlue$4 = colorScales.maasstrichtBlue;
|
|
1545
|
-
Object.assign(Object.assign({}, palette$
|
|
1545
|
+
Object.assign(Object.assign({}, palette$c), {
|
|
1546
1546
|
apple: apple$3.base,
|
|
1547
1547
|
appleDark20: apple$3.darken20,
|
|
1548
1548
|
appleDark50: apple$3.darken50,
|
|
@@ -1575,7 +1575,7 @@ var aliceBlue$1 = colorScales.aliceBlue,
|
|
|
1575
1575
|
vodka$1 = colorScales.vodka,
|
|
1576
1576
|
windsorGrey = colorScales.windsorGrey,
|
|
1577
1577
|
black$1 = colorScales.black;
|
|
1578
|
-
var palette$
|
|
1578
|
+
var palette$9 = {
|
|
1579
1579
|
black: black$1.base,
|
|
1580
1580
|
white: '#ffffff',
|
|
1581
1581
|
greyLight95: grey$1.lighten95,
|
|
@@ -1647,7 +1647,7 @@ var aliceBlue = colorScales.aliceBlue,
|
|
|
1647
1647
|
mintLeaf = colorScales.mintLeaf,
|
|
1648
1648
|
blueOblivion = colorScales.blueOblivion,
|
|
1649
1649
|
pastelBlue = colorScales.pastelBlue;
|
|
1650
|
-
var palette$
|
|
1650
|
+
var palette$8 = {
|
|
1651
1651
|
black: '#000000',
|
|
1652
1652
|
white: '#ffffff',
|
|
1653
1653
|
greyLight95: grey$3.lighten95,
|
|
@@ -1712,7 +1712,7 @@ var palette$7 = {
|
|
|
1712
1712
|
flagstone: flagstone.base
|
|
1713
1713
|
};
|
|
1714
1714
|
var maasstrichtBlue$1 = colorScales.maasstrichtBlue;
|
|
1715
|
-
var palette$
|
|
1715
|
+
var palette$7 = {
|
|
1716
1716
|
maasstrichtBlue: maasstrichtBlue$1.base,
|
|
1717
1717
|
maasstrichtBlueLight5: maasstrichtBlue$1.lighten5,
|
|
1718
1718
|
maasstrichtBlueLight10: maasstrichtBlue$1.lighten10,
|
|
@@ -1725,7 +1725,7 @@ var palette$6 = {
|
|
|
1725
1725
|
};
|
|
1726
1726
|
var violet1$2 = colorScales.violet1,
|
|
1727
1727
|
mauve$2 = colorScales.mauve;
|
|
1728
|
-
var palette$
|
|
1728
|
+
var palette$6 = Object.assign(Object.assign({}, palette$9), {
|
|
1729
1729
|
violet: violet1$2.base,
|
|
1730
1730
|
violetLight20: violet1$2.lighten20,
|
|
1731
1731
|
violetLight30: violet1$2.lighten30,
|
|
@@ -1737,7 +1737,7 @@ var palette$5 = Object.assign(Object.assign({}, palette$8), {
|
|
|
1737
1737
|
var apple = colorScales.apple,
|
|
1738
1738
|
currant = colorScales.currant,
|
|
1739
1739
|
hitPink = colorScales.hitPink;
|
|
1740
|
-
var palette$
|
|
1740
|
+
var palette$5 = Object.assign(Object.assign({}, palette$9), {
|
|
1741
1741
|
apple: apple.base,
|
|
1742
1742
|
appleLight10: apple.lighten10,
|
|
1743
1743
|
appleDark20: apple.darken20,
|
|
@@ -1751,7 +1751,7 @@ var palette$4 = Object.assign(Object.assign({}, palette$8), {
|
|
|
1751
1751
|
var scarletGum$1 = colorScales.scarletGum,
|
|
1752
1752
|
violet1$1 = colorScales.violet1,
|
|
1753
1753
|
mauve$1 = colorScales.mauve;
|
|
1754
|
-
var palette$
|
|
1754
|
+
var palette$4 = Object.assign(Object.assign({}, palette$9), {
|
|
1755
1755
|
scarletGumLight20: scarletGum$1.lighten20,
|
|
1756
1756
|
scarletGumLight30: scarletGum$1.lighten30,
|
|
1757
1757
|
scarletGumLight50: scarletGum$1.lighten50,
|
|
@@ -1766,11 +1766,15 @@ var palette$3 = Object.assign(Object.assign({}, palette$8), {
|
|
|
1766
1766
|
violet: violet1$1.base,
|
|
1767
1767
|
mauve: mauve$1.base
|
|
1768
1768
|
});
|
|
1769
|
+
var violet$3 = colorScales.violet;
|
|
1770
|
+
var palette$3 = Object.assign(Object.assign({}, palette$9), {
|
|
1771
|
+
violet: violet$3.base
|
|
1772
|
+
});
|
|
1769
1773
|
var scarletGum = colorScales.scarletGum,
|
|
1770
1774
|
violet1 = colorScales.violet1,
|
|
1771
1775
|
mauve = colorScales.mauve,
|
|
1772
1776
|
maasstrichtBlue = colorScales.maasstrichtBlue;
|
|
1773
|
-
var palette$2 = Object.assign(Object.assign({}, palette$
|
|
1777
|
+
var palette$2 = Object.assign(Object.assign({}, palette$9), {
|
|
1774
1778
|
scarletGumLight20: scarletGum.lighten20,
|
|
1775
1779
|
scarletGumLight30: scarletGum.lighten30,
|
|
1776
1780
|
scarletGumLight50: scarletGum.lighten50,
|
|
@@ -1793,7 +1797,7 @@ var palette$2 = Object.assign(Object.assign({}, palette$8), {
|
|
|
1793
1797
|
});
|
|
1794
1798
|
var royalBlue = colorScales.royalBlue,
|
|
1795
1799
|
frenchSky = colorScales.frenchSky;
|
|
1796
|
-
var palette$1 = Object.assign(Object.assign({}, palette$
|
|
1800
|
+
var palette$1 = Object.assign(Object.assign({}, palette$9), {
|
|
1797
1801
|
royalBlue: royalBlue.base,
|
|
1798
1802
|
royalBlueLight10: royalBlue.lighten10,
|
|
1799
1803
|
royalBlueLight80: royalBlue.lighten80,
|
|
@@ -1807,7 +1811,7 @@ var palette$1 = Object.assign(Object.assign({}, palette$8), {
|
|
|
1807
1811
|
var gold$1 = colorScales.gold,
|
|
1808
1812
|
policeBlue = colorScales.policeBlue,
|
|
1809
1813
|
black$2 = colorScales.black;
|
|
1810
|
-
var palette = Object.assign(Object.assign({}, palette$
|
|
1814
|
+
var palette = Object.assign(Object.assign({}, palette$9), {
|
|
1811
1815
|
blackLight30: black$2.lighten30,
|
|
1812
1816
|
blackLight90: black$2.lighten90,
|
|
1813
1817
|
goldLight20: gold$1.lighten20,
|
|
@@ -1825,95 +1829,95 @@ var palette = Object.assign(Object.assign({}, palette$8), {
|
|
|
1825
1829
|
var globalPalette$1 = {
|
|
1826
1830
|
// Updated 21 / Nov / 22
|
|
1827
1831
|
// Surfaces
|
|
1828
|
-
defaultGlobalSurface: palette$
|
|
1829
|
-
onDefaultGlobalSurface: palette$
|
|
1830
|
-
neutralGlobalSurface: palette$
|
|
1831
|
-
mutedOnDefaultGlobalSurface: palette$
|
|
1832
|
-
inactiveOnDefaultGlobalSurface: palette$
|
|
1833
|
-
disabledOnDefaultGlobalSurface: palette$
|
|
1834
|
-
darkGlobalSurface: palette$
|
|
1835
|
-
onDarkGlobalSurface: palette$
|
|
1836
|
-
overlayGlobalSurface: palette$
|
|
1832
|
+
defaultGlobalSurface: palette$9.white,
|
|
1833
|
+
onDefaultGlobalSurface: palette$9.maasstrichtBlue,
|
|
1834
|
+
neutralGlobalSurface: palette$9.greyLight90,
|
|
1835
|
+
mutedOnDefaultGlobalSurface: palette$9.maasstrichtBlueLight30,
|
|
1836
|
+
inactiveOnDefaultGlobalSurface: palette$9.maasstrichtBlueLight50,
|
|
1837
|
+
disabledOnDefaultGlobalSurface: palette$9.greyLight30,
|
|
1838
|
+
darkGlobalSurface: palette$9.maasstrichtBlue,
|
|
1839
|
+
onDarkGlobalSurface: palette$9.white,
|
|
1840
|
+
overlayGlobalSurface: palette$9.black,
|
|
1837
1841
|
// Outlines
|
|
1838
|
-
primaryOutline: palette$
|
|
1839
|
-
secondaryOutline: palette$
|
|
1840
|
-
inactiveOutline: palette$
|
|
1841
|
-
disabledOutline: palette$
|
|
1842
|
+
primaryOutline: palette$9.maasstrichtBlue,
|
|
1843
|
+
secondaryOutline: palette$9.greyLight75,
|
|
1844
|
+
inactiveOutline: palette$9.maasstrichtBlueLight50,
|
|
1845
|
+
disabledOutline: palette$9.greyLight30,
|
|
1842
1846
|
// Accents
|
|
1843
|
-
error: palette$
|
|
1844
|
-
mutedError: palette$
|
|
1845
|
-
errorSurface: palette$
|
|
1846
|
-
onErrorSurface: palette$
|
|
1847
|
-
warning: palette$
|
|
1848
|
-
mutedWarning: palette$
|
|
1849
|
-
warningSurface: palette$
|
|
1850
|
-
onWarningSurface: palette$
|
|
1851
|
-
success: palette$
|
|
1852
|
-
mutedSuccess: palette$
|
|
1853
|
-
successSurface: palette$
|
|
1854
|
-
onSuccessSurface: palette$
|
|
1855
|
-
info: palette$
|
|
1856
|
-
mutedInfo: palette$
|
|
1857
|
-
infoSurface: palette$
|
|
1858
|
-
onInfoSurface: palette$
|
|
1859
|
-
archived: palette$
|
|
1860
|
-
mutedArchived: palette$
|
|
1861
|
-
archivedSurface: palette$
|
|
1862
|
-
onArchivedSurface: palette$
|
|
1847
|
+
error: palette$9.pastelRed,
|
|
1848
|
+
mutedError: palette$9.pastelRedLight20,
|
|
1849
|
+
errorSurface: palette$9.linen,
|
|
1850
|
+
onErrorSurface: palette$9.amaranthaRed,
|
|
1851
|
+
warning: palette$9.mellowApricot,
|
|
1852
|
+
mutedWarning: palette$9.mellowApricotLight20,
|
|
1853
|
+
warningSurface: palette$9.seashell,
|
|
1854
|
+
onWarningSurface: palette$9.orangeBrown,
|
|
1855
|
+
success: palette$9.emerald,
|
|
1856
|
+
mutedSuccess: palette$9.emeraldLight20,
|
|
1857
|
+
successSurface: palette$9.honeydew,
|
|
1858
|
+
onSuccessSurface: palette$9.pineGreen,
|
|
1859
|
+
info: palette$9.vodka,
|
|
1860
|
+
mutedInfo: palette$9.vodkaLight20,
|
|
1861
|
+
infoSurface: palette$9.aliceBlue,
|
|
1862
|
+
onInfoSurface: palette$9.gentianFlower,
|
|
1863
|
+
archived: palette$9.silverChalice,
|
|
1864
|
+
mutedArchived: palette$9.silverChaliceLight20,
|
|
1865
|
+
archivedSurface: palette$9.cumberlandFog,
|
|
1866
|
+
onArchivedSurface: palette$9.windsorGrey
|
|
1863
1867
|
// End of Updated 21 / Nov / 22
|
|
1864
1868
|
};
|
|
1865
1869
|
|
|
1866
|
-
var swagBrandSystemPallete = {
|
|
1867
|
-
primary: palette$
|
|
1868
|
-
onPrimary: palette$
|
|
1869
|
-
secondary: palette$
|
|
1870
|
-
onSecondary: palette$
|
|
1871
|
-
defaultSurface: palette$
|
|
1872
|
-
highlightedSurface: palette$
|
|
1873
|
-
pressedSurface: palette$
|
|
1874
|
-
decorativePrimary: palette$
|
|
1875
|
-
decorativePrimarySurface: palette$
|
|
1870
|
+
var swagBrandSystemPallete$1 = {
|
|
1871
|
+
primary: palette$4.scarletGum,
|
|
1872
|
+
onPrimary: palette$4.white,
|
|
1873
|
+
secondary: palette$4.scarletGumLight30,
|
|
1874
|
+
onSecondary: palette$4.white,
|
|
1875
|
+
defaultSurface: palette$4.greyLight90,
|
|
1876
|
+
highlightedSurface: palette$4.scarletGumLight90,
|
|
1877
|
+
pressedSurface: palette$4.scarletGumDark20,
|
|
1878
|
+
decorativePrimary: palette$4.white,
|
|
1879
|
+
decorativePrimarySurface: palette$4.maasstrichtBlueLight80
|
|
1876
1880
|
};
|
|
1877
|
-
var swagSystemPalette = _objectSpread2(_objectSpread2({}, globalPalette$1), swagBrandSystemPallete);
|
|
1881
|
+
var swagSystemPalette$1 = _objectSpread2(_objectSpread2({}, globalPalette$1), swagBrandSystemPallete$1);
|
|
1878
1882
|
|
|
1879
1883
|
var globalPalette = {
|
|
1880
1884
|
// Updated 21 / Nov / 22
|
|
1881
1885
|
// Surfaces
|
|
1882
|
-
defaultGlobalSurface: palette$
|
|
1883
|
-
onDefaultGlobalSurface: palette$
|
|
1884
|
-
neutralGlobalSurface: palette$
|
|
1885
|
-
mutedOnDefaultGlobalSurface: palette$
|
|
1886
|
-
inactiveOnDefaultGlobalSurface: palette$
|
|
1887
|
-
disabledOnDefaultGlobalSurface: palette$
|
|
1888
|
-
darkGlobalSurface: palette$
|
|
1889
|
-
onDarkGlobalSurface: palette$
|
|
1890
|
-
overlayGlobalSurface: palette$
|
|
1886
|
+
defaultGlobalSurface: palette$8.maasstrichtBlue,
|
|
1887
|
+
onDefaultGlobalSurface: palette$8.white,
|
|
1888
|
+
neutralGlobalSurface: palette$8.maasstrichtBlueLight15,
|
|
1889
|
+
mutedOnDefaultGlobalSurface: palette$8.maasstrichtBlueLight70,
|
|
1890
|
+
inactiveOnDefaultGlobalSurface: palette$8.maasstrichtBlueLight60,
|
|
1891
|
+
disabledOnDefaultGlobalSurface: palette$8.greyDark20,
|
|
1892
|
+
darkGlobalSurface: palette$8.white,
|
|
1893
|
+
onDarkGlobalSurface: palette$8.maasstrichtBlue,
|
|
1894
|
+
overlayGlobalSurface: palette$8.greyDark30,
|
|
1891
1895
|
// Outlines
|
|
1892
|
-
primaryOutline: palette$
|
|
1893
|
-
secondaryOutline: palette$
|
|
1894
|
-
inactiveOutline: palette$
|
|
1895
|
-
disabledOutline: palette$
|
|
1896
|
+
primaryOutline: palette$8.white,
|
|
1897
|
+
secondaryOutline: palette$8.maasstrichtBlueLight10,
|
|
1898
|
+
inactiveOutline: palette$8.maasstrichtBlueLight60,
|
|
1899
|
+
disabledOutline: palette$8.greyDark20,
|
|
1896
1900
|
// Accents
|
|
1897
|
-
error: palette$
|
|
1898
|
-
mutedError: palette$
|
|
1899
|
-
errorSurface: palette$
|
|
1900
|
-
onErrorSurface: palette$
|
|
1901
|
-
warning: palette$
|
|
1902
|
-
mutedWarning: palette$
|
|
1903
|
-
warningSurface: palette$
|
|
1904
|
-
onWarningSurface: palette$
|
|
1905
|
-
success: palette$
|
|
1906
|
-
mutedSuccess: palette$
|
|
1907
|
-
successSurface: palette$
|
|
1908
|
-
onSuccessSurface: palette$
|
|
1909
|
-
info: palette$
|
|
1910
|
-
mutedInfo: palette$
|
|
1911
|
-
infoSurface: palette$
|
|
1912
|
-
onInfoSurface: palette$
|
|
1913
|
-
archived: palette$
|
|
1914
|
-
mutedArchived: palette$
|
|
1915
|
-
archivedSurface: palette$
|
|
1916
|
-
onArchivedSurface: palette$
|
|
1901
|
+
error: palette$8.vermilionDark10,
|
|
1902
|
+
mutedError: palette$8.vermilionLight20,
|
|
1903
|
+
errorSurface: palette$8.moussaka,
|
|
1904
|
+
onErrorSurface: palette$8.indianDance,
|
|
1905
|
+
warning: palette$8.theatreGold,
|
|
1906
|
+
mutedWarning: palette$8.theatreGoldLight20,
|
|
1907
|
+
warningSurface: palette$8.uniformGreen,
|
|
1908
|
+
onWarningSurface: palette$8.blazingBonfire,
|
|
1909
|
+
success: palette$8.pineGreenDark10,
|
|
1910
|
+
mutedSuccess: palette$8.pineGreenLight20,
|
|
1911
|
+
successSurface: palette$8.deepIntoTheJungle,
|
|
1912
|
+
onSuccessSurface: palette$8.mintLeaf,
|
|
1913
|
+
info: palette$8.ultramarineBlueDark10,
|
|
1914
|
+
mutedInfo: palette$8.ultramarineBlueLight20,
|
|
1915
|
+
infoSurface: palette$8.blueOblivion,
|
|
1916
|
+
onInfoSurface: palette$8.pastelBlue,
|
|
1917
|
+
archived: palette$8.sonicSilverDark10,
|
|
1918
|
+
mutedArchived: palette$8.sonicSilverLight50,
|
|
1919
|
+
archivedSurface: palette$8.bigStone,
|
|
1920
|
+
onArchivedSurface: palette$8.flagstone
|
|
1917
1921
|
// End of Updated 21 / Nov / 22
|
|
1918
1922
|
};
|
|
1919
1923
|
|
|
@@ -1930,6 +1934,19 @@ var swagDarkBrandSystemPalette = {
|
|
|
1930
1934
|
};
|
|
1931
1935
|
var swagDarkSystemPalette = _objectSpread2(_objectSpread2({}, globalPalette), swagDarkBrandSystemPalette);
|
|
1932
1936
|
|
|
1937
|
+
var swagBrandSystemPallete = {
|
|
1938
|
+
primary: palette$3.violet,
|
|
1939
|
+
onPrimary: '#FDFBFF',
|
|
1940
|
+
secondary: '#460078',
|
|
1941
|
+
onSecondary: palette$3.white,
|
|
1942
|
+
defaultSurface: '#FDFBFF',
|
|
1943
|
+
highlightedSurface: '#F1E9FB',
|
|
1944
|
+
pressedSurface: '#380060',
|
|
1945
|
+
decorativePrimary: '#FDFBFF',
|
|
1946
|
+
decorativePrimarySurface: '#B382FD'
|
|
1947
|
+
};
|
|
1948
|
+
var swagSystemPalette = _objectSpread2(_objectSpread2({}, globalPalette$1), swagBrandSystemPallete);
|
|
1949
|
+
|
|
1933
1950
|
var workBrandSystemPallete = {
|
|
1934
1951
|
primary: palette.black,
|
|
1935
1952
|
onPrimary: palette.white,
|
|
@@ -1941,20 +1958,20 @@ var workBrandSystemPallete = {
|
|
|
1941
1958
|
decorativePrimary: palette.gold,
|
|
1942
1959
|
decorativePrimarySurface: palette.goldLight80
|
|
1943
1960
|
};
|
|
1944
|
-
var workSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette), workBrandSystemPallete);
|
|
1961
|
+
var workSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette$1), workBrandSystemPallete);
|
|
1945
1962
|
|
|
1946
1963
|
var jobsBrandSystemPallete = {
|
|
1947
|
-
primary: palette$
|
|
1948
|
-
onPrimary: palette$
|
|
1949
|
-
secondary: palette$
|
|
1950
|
-
onSecondary: palette$
|
|
1951
|
-
defaultSurface: palette$
|
|
1952
|
-
highlightedSurface: palette$
|
|
1953
|
-
pressedSurface: palette$
|
|
1954
|
-
decorativePrimary: palette$
|
|
1955
|
-
decorativePrimarySurface: palette$
|
|
1964
|
+
primary: palette$5.apple,
|
|
1965
|
+
onPrimary: palette$5.white,
|
|
1966
|
+
secondary: palette$5.maasstrichtBlueLight30,
|
|
1967
|
+
onSecondary: palette$5.white,
|
|
1968
|
+
defaultSurface: palette$5.white,
|
|
1969
|
+
highlightedSurface: palette$5.hitPinkLight90,
|
|
1970
|
+
pressedSurface: palette$5.appleDark20,
|
|
1971
|
+
decorativePrimary: palette$5.hitPink,
|
|
1972
|
+
decorativePrimarySurface: palette$5.hitPinkLight80
|
|
1956
1973
|
};
|
|
1957
|
-
var jobsSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette), jobsBrandSystemPallete);
|
|
1974
|
+
var jobsSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette$1), jobsBrandSystemPallete);
|
|
1958
1975
|
|
|
1959
1976
|
var walletBrandSystemPallete = {
|
|
1960
1977
|
primary: palette$1.royalBlue,
|
|
@@ -1967,20 +1984,20 @@ var walletBrandSystemPallete = {
|
|
|
1967
1984
|
decorativePrimary: palette$1.frenchSky,
|
|
1968
1985
|
decorativePrimarySurface: palette$1.frenchSkyLight80
|
|
1969
1986
|
};
|
|
1970
|
-
var walletSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette), walletBrandSystemPallete);
|
|
1987
|
+
var walletSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette$1), walletBrandSystemPallete);
|
|
1971
1988
|
|
|
1972
1989
|
var eBensBrandSystemPallete = {
|
|
1973
|
-
primary: palette$
|
|
1974
|
-
onPrimary: palette$
|
|
1975
|
-
secondary: palette$
|
|
1976
|
-
onSecondary: palette$
|
|
1977
|
-
defaultSurface: palette$
|
|
1978
|
-
highlightedSurface: palette$
|
|
1979
|
-
pressedSurface: palette$
|
|
1980
|
-
decorativePrimary: palette$
|
|
1981
|
-
decorativePrimarySurface: palette$
|
|
1982
|
-
};
|
|
1983
|
-
var eBensSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette), eBensBrandSystemPallete);
|
|
1990
|
+
primary: palette$6.violet,
|
|
1991
|
+
onPrimary: palette$6.white,
|
|
1992
|
+
secondary: palette$6.violetLight30,
|
|
1993
|
+
onSecondary: palette$6.white,
|
|
1994
|
+
defaultSurface: palette$6.white,
|
|
1995
|
+
highlightedSurface: palette$6.violetLight90,
|
|
1996
|
+
pressedSurface: palette$6.violetDark20,
|
|
1997
|
+
decorativePrimary: palette$6.mauve,
|
|
1998
|
+
decorativePrimarySurface: palette$6.mauveLight80
|
|
1999
|
+
};
|
|
2000
|
+
var eBensSystemPalette = _objectSpread2(_objectSpread2({}, swagSystemPalette$1), eBensBrandSystemPallete);
|
|
1984
2001
|
|
|
1985
2002
|
var BASE_WIDTH = 390; // Based on iPhone 13's viewport size
|
|
1986
2003
|
var horizontalScale = function horizontalScale(size) {
|
|
@@ -2493,7 +2510,8 @@ var getCardTheme = function getCardTheme(theme) {
|
|
|
2493
2510
|
success: theme.colors.success,
|
|
2494
2511
|
warning: theme.colors.warning,
|
|
2495
2512
|
danger: theme.colors.error,
|
|
2496
|
-
archived: theme.colors.archived
|
|
2513
|
+
archived: theme.colors.archived,
|
|
2514
|
+
neutral: theme.colors.neutralGlobalSurface
|
|
2497
2515
|
};
|
|
2498
2516
|
var sizes = {
|
|
2499
2517
|
indicatorWidth: theme.sizes.medium
|
|
@@ -3774,7 +3792,7 @@ var getTypographyTheme = function getTypographyTheme(theme) {
|
|
|
3774
3792
|
|
|
3775
3793
|
var getTheme$1 = function getTheme() {
|
|
3776
3794
|
var scale = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : scale$1;
|
|
3777
|
-
var systemPallete = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : swagSystemPalette;
|
|
3795
|
+
var systemPallete = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : swagSystemPalette$1;
|
|
3778
3796
|
var globalTheme = getGlobalTheme(scale, systemPallete);
|
|
3779
3797
|
return _objectSpread2(_objectSpread2({}, globalTheme), {}, {
|
|
3780
3798
|
__hd__: {
|
|
@@ -4998,7 +5016,7 @@ var ThemeSwitcher = function ThemeSwitcher(_ref) {
|
|
|
4998
5016
|
var theme = React.useMemo(function () {
|
|
4999
5017
|
switch (name) {
|
|
5000
5018
|
case 'swag':
|
|
5001
|
-
return getTheme$1(scale$1, swagSystemPalette);
|
|
5019
|
+
return getTheme$1(scale$1, swagSystemPalette$1);
|
|
5002
5020
|
case 'work':
|
|
5003
5021
|
return getTheme$1(scale$1, workSystemPalette);
|
|
5004
5022
|
case 'jobs':
|
|
@@ -8348,7 +8366,7 @@ var shuffleArray = function shuffleArray(array) {
|
|
|
8348
8366
|
*/
|
|
8349
8367
|
var useAvatarColors = function useAvatarColors() {
|
|
8350
8368
|
var shuffledColors = React.useMemo(function () {
|
|
8351
|
-
return shuffleArray(Object.values(palette$
|
|
8369
|
+
return shuffleArray(Object.values(palette$7));
|
|
8352
8370
|
}, []);
|
|
8353
8371
|
return shuffledColors;
|
|
8354
8372
|
};
|
|
@@ -36176,7 +36194,8 @@ exports.getTheme = getTheme$1;
|
|
|
36176
36194
|
exports.jobsSystemPalette = jobsSystemPalette;
|
|
36177
36195
|
exports.scale = scale;
|
|
36178
36196
|
exports.swagDarkSystemPalette = swagDarkSystemPalette;
|
|
36179
|
-
exports.
|
|
36197
|
+
exports.swagLightSystemPalette = swagSystemPalette;
|
|
36198
|
+
exports.swagSystemPalette = swagSystemPalette$1;
|
|
36180
36199
|
exports.theme = defaultTheme;
|
|
36181
36200
|
exports.useAvatarColors = useAvatarColors;
|
|
36182
36201
|
exports.useTheme = useTheme;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hero-design/rn",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.67.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"@emotion/native": "^11.9.3",
|
|
23
23
|
"@emotion/primitives-core": "11.0.0",
|
|
24
24
|
"@emotion/react": "^11.9.3",
|
|
25
|
-
"@hero-design/colors": "8.
|
|
25
|
+
"@hero-design/colors": "8.44.0",
|
|
26
26
|
"date-fns": "^2.16.1",
|
|
27
27
|
"hero-editor": "^1.9.21",
|
|
28
28
|
"nanoid": "^4.0.2"
|
|
@@ -2,7 +2,13 @@ import { View } from 'react-native';
|
|
|
2
2
|
import styled from '@emotion/native';
|
|
3
3
|
|
|
4
4
|
const StyledCard = styled(View)<{
|
|
5
|
-
themeIntent?:
|
|
5
|
+
themeIntent?:
|
|
6
|
+
| 'primary'
|
|
7
|
+
| 'success'
|
|
8
|
+
| 'warning'
|
|
9
|
+
| 'danger'
|
|
10
|
+
| 'archived'
|
|
11
|
+
| 'neutral';
|
|
6
12
|
}>(({ theme, themeIntent }) => ({
|
|
7
13
|
...(themeIntent !== undefined && {
|
|
8
14
|
backgroundColor: theme.__hd__.card.colors[themeIntent],
|
|
@@ -260,6 +260,70 @@ exports[`Card renders correctly when intent is primary 1`] = `
|
|
|
260
260
|
</View>
|
|
261
261
|
`;
|
|
262
262
|
|
|
263
|
+
exports[`Card renders correctly when intent is subdued 1`] = `
|
|
264
|
+
<View
|
|
265
|
+
style={
|
|
266
|
+
{
|
|
267
|
+
"flex": 1,
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
>
|
|
271
|
+
<View
|
|
272
|
+
style={
|
|
273
|
+
[
|
|
274
|
+
{
|
|
275
|
+
"borderRadius": 12,
|
|
276
|
+
"overflow": "hidden",
|
|
277
|
+
},
|
|
278
|
+
undefined,
|
|
279
|
+
]
|
|
280
|
+
}
|
|
281
|
+
themeIntent="subdued"
|
|
282
|
+
>
|
|
283
|
+
<Text
|
|
284
|
+
allowFontScaling={false}
|
|
285
|
+
style={
|
|
286
|
+
[
|
|
287
|
+
{
|
|
288
|
+
"color": "#001f23",
|
|
289
|
+
"fontFamily": "BeVietnamPro-Regular",
|
|
290
|
+
"fontSize": 14,
|
|
291
|
+
"letterSpacing": 0.48,
|
|
292
|
+
"lineHeight": 22,
|
|
293
|
+
},
|
|
294
|
+
undefined,
|
|
295
|
+
]
|
|
296
|
+
}
|
|
297
|
+
themeIntent="body"
|
|
298
|
+
themeTypeface="neutral"
|
|
299
|
+
themeVariant="small"
|
|
300
|
+
>
|
|
301
|
+
Card Content
|
|
302
|
+
</Text>
|
|
303
|
+
</View>
|
|
304
|
+
<View
|
|
305
|
+
pointerEvents="box-none"
|
|
306
|
+
position="bottom"
|
|
307
|
+
style={
|
|
308
|
+
[
|
|
309
|
+
{
|
|
310
|
+
"bottom": 0,
|
|
311
|
+
"elevation": 9999,
|
|
312
|
+
"flexDirection": "column-reverse",
|
|
313
|
+
"left": 0,
|
|
314
|
+
"paddingHorizontal": 24,
|
|
315
|
+
"paddingVertical": 16,
|
|
316
|
+
"position": "absolute",
|
|
317
|
+
"right": 0,
|
|
318
|
+
"top": 0,
|
|
319
|
+
},
|
|
320
|
+
undefined,
|
|
321
|
+
]
|
|
322
|
+
}
|
|
323
|
+
/>
|
|
324
|
+
</View>
|
|
325
|
+
`;
|
|
326
|
+
|
|
263
327
|
exports[`Card renders correctly when intent is success 1`] = `
|
|
264
328
|
<View
|
|
265
329
|
style={
|
|
@@ -12,7 +12,13 @@ export interface CardProps extends ViewProps {
|
|
|
12
12
|
/**
|
|
13
13
|
* Visual intent color to apply to card.
|
|
14
14
|
*/
|
|
15
|
-
intent?:
|
|
15
|
+
intent?:
|
|
16
|
+
| 'primary'
|
|
17
|
+
| 'success'
|
|
18
|
+
| 'warning'
|
|
19
|
+
| 'danger'
|
|
20
|
+
| 'archived'
|
|
21
|
+
| 'neutral';
|
|
16
22
|
/**
|
|
17
23
|
* Additional style.
|
|
18
24
|
*/
|
package/src/index.ts
CHANGED
|
@@ -3,6 +3,7 @@ import theme, {
|
|
|
3
3
|
ThemeProvider,
|
|
4
4
|
useTheme,
|
|
5
5
|
swagSystemPalette,
|
|
6
|
+
swagLightSystemPalette,
|
|
6
7
|
swagDarkSystemPalette,
|
|
7
8
|
workSystemPalette,
|
|
8
9
|
jobsSystemPalette,
|
|
@@ -77,6 +78,7 @@ export {
|
|
|
77
78
|
ThemeSwitcher,
|
|
78
79
|
withTheme,
|
|
79
80
|
swagSystemPalette,
|
|
81
|
+
swagLightSystemPalette,
|
|
80
82
|
swagDarkSystemPalette,
|
|
81
83
|
workSystemPalette,
|
|
82
84
|
jobsSystemPalette,
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
+
|
|
3
|
+
exports[`swagDark returns correct theme object 1`] = `
|
|
4
|
+
{
|
|
5
|
+
"archived": "#abacaf",
|
|
6
|
+
"archivedSurface": "#dadbde",
|
|
7
|
+
"darkGlobalSurface": "#001f23",
|
|
8
|
+
"decorativePrimary": "#FDFBFF",
|
|
9
|
+
"decorativePrimarySurface": "#B382FD",
|
|
10
|
+
"defaultGlobalSurface": "#ffffff",
|
|
11
|
+
"defaultSurface": "#FDFBFF",
|
|
12
|
+
"disabledOnDefaultGlobalSurface": "#bfc1c5",
|
|
13
|
+
"disabledOutline": "#bfc1c5",
|
|
14
|
+
"error": "#f46363",
|
|
15
|
+
"errorSurface": "#fcebe7",
|
|
16
|
+
"highlightedSurface": "#F1E9FB",
|
|
17
|
+
"inactiveOnDefaultGlobalSurface": "#808f91",
|
|
18
|
+
"inactiveOutline": "#808f91",
|
|
19
|
+
"info": "#b5c3fd",
|
|
20
|
+
"infoSurface": "#ecf0ff",
|
|
21
|
+
"mutedArchived": "#bcbdbf",
|
|
22
|
+
"mutedError": "#f68282",
|
|
23
|
+
"mutedInfo": "#c4cffd",
|
|
24
|
+
"mutedOnDefaultGlobalSurface": "#4d6265",
|
|
25
|
+
"mutedSuccess": "#7bd897",
|
|
26
|
+
"mutedWarning": "#ffcb8d",
|
|
27
|
+
"neutralGlobalSurface": "#f6f6f7",
|
|
28
|
+
"onArchivedSurface": "#606065",
|
|
29
|
+
"onDarkGlobalSurface": "#ffffff",
|
|
30
|
+
"onDefaultGlobalSurface": "#001f23",
|
|
31
|
+
"onErrorSurface": "#cb300a",
|
|
32
|
+
"onInfoSurface": "#355bfb",
|
|
33
|
+
"onPrimary": "#FDFBFF",
|
|
34
|
+
"onSecondary": "#ffffff",
|
|
35
|
+
"onSuccessSurface": "#017d6d",
|
|
36
|
+
"onWarningSurface": "#ac5d00",
|
|
37
|
+
"overlayGlobalSurface": "#000000",
|
|
38
|
+
"pressedSurface": "#380060",
|
|
39
|
+
"primary": "#7622d7",
|
|
40
|
+
"primaryOutline": "#001f23",
|
|
41
|
+
"secondary": "#460078",
|
|
42
|
+
"secondaryOutline": "#e8e9ea",
|
|
43
|
+
"success": "#5ace7d",
|
|
44
|
+
"successSurface": "#f0fef4",
|
|
45
|
+
"warning": "#ffbe71",
|
|
46
|
+
"warningSurface": "#fff6eb",
|
|
47
|
+
}
|
|
48
|
+
`;
|