ferns-ui 0.2.2 → 0.2.3
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/ActionSheet.js.map +1 -1
- package/dist/Common.d.ts +1 -1
- package/dist/DateTimeActionSheet.js.map +1 -1
- package/dist/DecimalRangeActionSheet.js.map +1 -1
- package/dist/ErrorBoundary.d.ts +1 -1
- package/dist/Field.d.ts +12 -14
- package/dist/Field.js +95 -98
- package/dist/Field.js.map +1 -1
- package/dist/HeightActionSheet.js.map +1 -1
- package/dist/NumberPickerActionSheet.js.map +1 -1
- package/dist/PickerSelect.d.ts +4 -4
- package/dist/SplitPage.js.map +1 -1
- package/dist/TextField.js.map +1 -1
- package/dist/TextFieldNumberActionSheet.js.map +1 -1
- package/dist/Unifier.js +1 -9
- package/dist/Unifier.js.map +1 -1
- package/package.json +26 -25
- package/src/Field.tsx +91 -98
- package/src/TextFieldNumberActionSheet.tsx +1 -1
- package/dist/Banner.stories.d.ts +0 -1
- package/dist/Banner.stories.js +0 -13
- package/dist/Banner.stories.js.map +0 -1
- package/dist/Box.stories.d.ts +0 -1
- package/dist/Box.stories.js +0 -45
- package/dist/Box.stories.js.map +0 -1
- package/dist/Button.stories.d.ts +0 -1
- package/dist/Button.stories.js +0 -41
- package/dist/Button.stories.js.map +0 -1
- package/dist/Card.stories.d.ts +0 -6
- package/dist/Card.stories.js +0 -18
- package/dist/Card.stories.js.map +0 -1
- package/dist/CheckBox.stories.d.ts +0 -1
- package/dist/CheckBox.stories.js +0 -28
- package/dist/CheckBox.stories.js.map +0 -1
- package/dist/Field.stories.d.ts +0 -6
- package/dist/Field.stories.js +0 -38
- package/dist/Field.stories.js.map +0 -1
- package/dist/Form.stories.d.ts +0 -6
- package/dist/Form.stories.js +0 -36
- package/dist/Form.stories.js.map +0 -1
- package/dist/HeaderButtons.stories.d.ts +0 -6
- package/dist/HeaderButtons.stories.js +0 -6
- package/dist/HeaderButtons.stories.js.map +0 -1
- package/dist/Heading.stories.d.ts +0 -1
- package/dist/Heading.stories.js +0 -22
- package/dist/Heading.stories.js.map +0 -1
- package/dist/Icon.stories.d.ts +0 -1
- package/dist/Icon.stories.js +0 -30
- package/dist/Icon.stories.js.map +0 -1
- package/dist/IconButton.stories.d.ts +0 -1
- package/dist/IconButton.stories.js +0 -16
- package/dist/IconButton.stories.js.map +0 -1
- package/dist/Link.stories.d.ts +0 -1
- package/dist/Link.stories.js +0 -18
- package/dist/Link.stories.js.map +0 -1
- package/dist/Mask.stories.d.ts +0 -1
- package/dist/Mask.stories.js +0 -28
- package/dist/Mask.stories.js.map +0 -1
- package/dist/Pill.stories.d.ts +0 -1
- package/dist/Pill.stories.js +0 -38
- package/dist/Pill.stories.js.map +0 -1
- package/dist/SegmentedControl.stories.d.ts +0 -1
- package/dist/SegmentedControl.stories.js +0 -31
- package/dist/SegmentedControl.stories.js.map +0 -1
- package/dist/SelectList.stories.d.ts +0 -1
- package/dist/SelectList.stories.js +0 -26
- package/dist/SelectList.stories.js.map +0 -1
- package/dist/Spinner.stories.d.ts +0 -1
- package/dist/Spinner.stories.js +0 -12
- package/dist/Spinner.stories.js.map +0 -1
- package/dist/SplitPage.stories.d.ts +0 -1
- package/dist/SplitPage.stories.js +0 -15
- package/dist/SplitPage.stories.js.map +0 -1
- package/dist/StorybookContainer.d.ts +0 -4
- package/dist/StorybookContainer.js +0 -8
- package/dist/StorybookContainer.js.map +0 -1
- package/dist/Switch.stories.d.ts +0 -1
- package/dist/Switch.stories.js +0 -34
- package/dist/Switch.stories.js.map +0 -1
- package/dist/Text.stories.d.ts +0 -1
- package/dist/Text.stories.js +0 -37
- package/dist/Text.stories.js.map +0 -1
- package/dist/TextArea.stories.d.ts +0 -10
- package/dist/TextArea.stories.js +0 -24
- package/dist/TextArea.stories.js.map +0 -1
- package/dist/TextField.stories.d.ts +0 -6
- package/dist/TextField.stories.js +0 -18
- package/dist/TextField.stories.js.map +0 -1
- package/dist/dist/ActionSheet.d.ts +0 -139
- package/dist/dist/ActionSheet.js +0 -637
- package/dist/dist/ActionSheet.js.map +0 -1
- package/dist/dist/Banner.d.ts +0 -12
- package/dist/dist/Banner.js +0 -49
- package/dist/dist/Banner.js.map +0 -1
- package/dist/dist/Banner.stories.d.ts +0 -1
- package/dist/dist/Banner.stories.js +0 -9
- package/dist/dist/Banner.stories.js.map +0 -1
- package/dist/dist/BlurBox.d.ts +0 -7
- package/dist/dist/BlurBox.js +0 -29
- package/dist/dist/BlurBox.js.map +0 -1
- package/dist/dist/BlurBox.native.d.ts +0 -9
- package/dist/dist/BlurBox.native.js +0 -32
- package/dist/dist/BlurBox.native.js.map +0 -1
- package/dist/dist/Body.d.ts +0 -12
- package/dist/dist/Body.js +0 -19
- package/dist/dist/Body.js.map +0 -1
- package/dist/dist/Box.d.ts +0 -205
- package/dist/dist/Box.js +0 -229
- package/dist/dist/Box.js.map +0 -1
- package/dist/dist/Box.stories.d.ts +0 -1
- package/dist/dist/Box.stories.js +0 -37
- package/dist/dist/Box.stories.js.map +0 -1
- package/dist/dist/Button.d.ts +0 -16
- package/dist/dist/Button.js +0 -98
- package/dist/dist/Button.js.map +0 -1
- package/dist/dist/Button.stories.d.ts +0 -13
- package/dist/dist/Button.stories.js +0 -26
- package/dist/dist/Button.stories.js.map +0 -1
- package/dist/dist/Card.d.ts +0 -6
- package/dist/dist/Card.js +0 -9
- package/dist/dist/Card.js.map +0 -1
- package/dist/dist/Card.stories.d.ts +0 -6
- package/dist/dist/Card.stories.js +0 -11
- package/dist/dist/Card.stories.js.map +0 -1
- package/dist/dist/CheckBox.d.ts +0 -8
- package/dist/dist/CheckBox.js +0 -23
- package/dist/dist/CheckBox.js.map +0 -1
- package/dist/dist/CheckBox.stories.d.ts +0 -1
- package/dist/dist/CheckBox.stories.js +0 -22
- package/dist/dist/CheckBox.stories.js.map +0 -1
- package/dist/dist/Common.d.ts +0 -5
- package/dist/dist/Common.js +0 -47
- package/dist/dist/Common.js.map +0 -1
- package/dist/dist/DateTimeActionSheet.d.ts +0 -5
- package/dist/dist/DateTimeActionSheet.js +0 -24
- package/dist/dist/DateTimeActionSheet.js.map +0 -1
- package/dist/dist/DecimalRangeActionSheet.d.ts +0 -9
- package/dist/dist/DecimalRangeActionSheet.js +0 -57
- package/dist/dist/DecimalRangeActionSheet.js.map +0 -1
- package/dist/dist/ErrorBoundary.d.ts +0 -12
- package/dist/dist/ErrorBoundary.js +0 -32
- package/dist/dist/ErrorBoundary.js.map +0 -1
- package/dist/dist/ErrorPage.d.ts +0 -7
- package/dist/dist/ErrorPage.js +0 -15
- package/dist/dist/ErrorPage.js.map +0 -1
- package/dist/dist/Field.d.ts +0 -17
- package/dist/dist/Field.js +0 -136
- package/dist/dist/Field.js.map +0 -1
- package/dist/dist/Field.stories.d.ts +0 -6
- package/dist/dist/Field.stories.js +0 -25
- package/dist/dist/Field.stories.js.map +0 -1
- package/dist/dist/FieldWithLabels.d.ts +0 -10
- package/dist/dist/FieldWithLabels.js +0 -7
- package/dist/dist/FieldWithLabels.js.map +0 -1
- package/dist/dist/FlatList.d.ts +0 -1
- package/dist/dist/FlatList.js +0 -4
- package/dist/dist/FlatList.js.map +0 -1
- package/dist/dist/Form.d.ts +0 -15
- package/dist/dist/Form.js +0 -56
- package/dist/dist/Form.js.map +0 -1
- package/dist/dist/Form.stories.d.ts +0 -6
- package/dist/dist/Form.stories.js +0 -27
- package/dist/dist/Form.stories.js.map +0 -1
- package/dist/dist/HeaderButtons.d.ts +0 -39
- package/dist/dist/HeaderButtons.js +0 -50
- package/dist/dist/HeaderButtons.js.map +0 -1
- package/dist/dist/HeaderButtons.stories.d.ts +0 -6
- package/dist/dist/HeaderButtons.stories.js +0 -7
- package/dist/dist/HeaderButtons.stories.js.map +0 -1
- package/dist/dist/Heading.d.ts +0 -32
- package/dist/dist/Heading.js +0 -47
- package/dist/dist/Heading.js.map +0 -1
- package/dist/dist/Heading.stories.d.ts +0 -1
- package/dist/dist/Heading.stories.js +0 -11
- package/dist/dist/Heading.stories.js.map +0 -1
- package/dist/dist/HeightActionSheet.d.ts +0 -9
- package/dist/dist/HeightActionSheet.js +0 -50
- package/dist/dist/HeightActionSheet.js.map +0 -1
- package/dist/dist/Icon.d.ts +0 -12
- package/dist/dist/Icon.js +0 -126
- package/dist/dist/Icon.js.map +0 -1
- package/dist/dist/Icon.stories.d.ts +0 -1
- package/dist/dist/Icon.stories.js +0 -11
- package/dist/dist/Icon.stories.js.map +0 -1
- package/dist/dist/IconButton.d.ts +0 -42
- package/dist/dist/IconButton.js +0 -41
- package/dist/dist/IconButton.js.map +0 -1
- package/dist/dist/IconButton.stories.d.ts +0 -1
- package/dist/dist/IconButton.stories.js +0 -8
- package/dist/dist/IconButton.stories.js.map +0 -1
- package/dist/dist/Image.d.ts +0 -9
- package/dist/dist/Image.js +0 -37
- package/dist/dist/Image.js.map +0 -1
- package/dist/dist/ImageBackground.d.ts +0 -6
- package/dist/dist/ImageBackground.js +0 -9
- package/dist/dist/ImageBackground.js.map +0 -1
- package/dist/dist/Layer.d.ts +0 -5
- package/dist/dist/Layer.js +0 -13
- package/dist/dist/Layer.js.map +0 -1
- package/dist/dist/Link.d.ts +0 -7
- package/dist/dist/Link.js +0 -13
- package/dist/dist/Link.js.map +0 -1
- package/dist/dist/Link.stories.d.ts +0 -1
- package/dist/dist/Link.stories.js +0 -8
- package/dist/dist/Link.stories.js.map +0 -1
- package/dist/dist/Mask.d.ts +0 -5
- package/dist/dist/Mask.js +0 -23
- package/dist/dist/Mask.js.map +0 -1
- package/dist/dist/Mask.stories.d.ts +0 -1
- package/dist/dist/Mask.stories.js +0 -13
- package/dist/dist/Mask.stories.js.map +0 -1
- package/dist/dist/MediaQuery.d.ts +0 -2
- package/dist/dist/MediaQuery.js +0 -34
- package/dist/dist/MediaQuery.js.map +0 -1
- package/dist/dist/Meta.d.ts +0 -6
- package/dist/dist/Meta.js +0 -8
- package/dist/dist/Meta.js.map +0 -1
- package/dist/dist/ModalSheet.d.ts +0 -3
- package/dist/dist/ModalSheet.js +0 -43
- package/dist/dist/ModalSheet.js.map +0 -1
- package/dist/dist/NumberPickerActionSheet.d.ts +0 -5
- package/dist/dist/NumberPickerActionSheet.js +0 -25
- package/dist/dist/NumberPickerActionSheet.js.map +0 -1
- package/dist/dist/Page.d.ts +0 -9
- package/dist/dist/Page.js +0 -26
- package/dist/dist/Page.js.map +0 -1
- package/dist/dist/Permissions.d.ts +0 -1
- package/dist/dist/Permissions.js +0 -36
- package/dist/dist/Permissions.js.map +0 -1
- package/dist/dist/PickerSelect.d.ts +0 -172
- package/dist/dist/PickerSelect.js +0 -403
- package/dist/dist/PickerSelect.js.map +0 -1
- package/dist/dist/Pill.d.ts +0 -7
- package/dist/dist/Pill.js +0 -10
- package/dist/dist/Pill.js.map +0 -1
- package/dist/dist/Pill.stories.d.ts +0 -1
- package/dist/dist/Pill.stories.js +0 -36
- package/dist/dist/Pill.stories.js.map +0 -1
- package/dist/dist/Pog.d.ts +0 -7
- package/dist/dist/Pog.js +0 -144
- package/dist/dist/Pog.js.map +0 -1
- package/dist/dist/ProgressBar.d.ts +0 -16
- package/dist/dist/ProgressBar.js +0 -40
- package/dist/dist/ProgressBar.js.map +0 -1
- package/dist/dist/ScrollView.d.ts +0 -1
- package/dist/dist/ScrollView.js +0 -4
- package/dist/dist/ScrollView.js.map +0 -1
- package/dist/dist/SegmentedControl.d.ts +0 -9
- package/dist/dist/SegmentedControl.js +0 -18
- package/dist/dist/SegmentedControl.js.map +0 -1
- package/dist/dist/SegmentedControl.stories.d.ts +0 -1
- package/dist/dist/SegmentedControl.stories.js +0 -32
- package/dist/dist/SegmentedControl.stories.js.map +0 -1
- package/dist/dist/SelectList.d.ts +0 -9
- package/dist/dist/SelectList.js +0 -29
- package/dist/dist/SelectList.js.map +0 -1
- package/dist/dist/SelectList.stories.d.ts +0 -1
- package/dist/dist/SelectList.stories.js +0 -24
- package/dist/dist/SelectList.stories.js.map +0 -1
- package/dist/dist/Spinner.d.ts +0 -44
- package/dist/dist/Spinner.js +0 -58
- package/dist/dist/Spinner.js.map +0 -1
- package/dist/dist/Spinner.stories.d.ts +0 -1
- package/dist/dist/Spinner.stories.js +0 -10
- package/dist/dist/Spinner.stories.js.map +0 -1
- package/dist/dist/SplitPage.d.ts +0 -7
- package/dist/dist/SplitPage.js +0 -20
- package/dist/dist/SplitPage.js.map +0 -1
- package/dist/dist/SplitPage.stories.d.ts +0 -1
- package/dist/dist/SplitPage.stories.js +0 -7
- package/dist/dist/SplitPage.stories.js.map +0 -1
- package/dist/dist/StorybookContainer.d.ts +0 -7
- package/dist/dist/StorybookContainer.js +0 -9
- package/dist/dist/StorybookContainer.js.map +0 -1
- package/dist/dist/Switch.d.ts +0 -6
- package/dist/dist/Switch.js +0 -10
- package/dist/dist/Switch.js.map +0 -1
- package/dist/dist/Switch.stories.d.ts +0 -1
- package/dist/dist/Switch.stories.js +0 -27
- package/dist/dist/Switch.stories.js.map +0 -1
- package/dist/dist/TapToEdit.d.ts +0 -9
- package/dist/dist/TapToEdit.js +0 -27
- package/dist/dist/TapToEdit.js.map +0 -1
- package/dist/dist/Text.d.ts +0 -36
- package/dist/dist/Text.js +0 -86
- package/dist/dist/Text.js.map +0 -1
- package/dist/dist/Text.stories.d.ts +0 -1
- package/dist/dist/Text.stories.js +0 -13
- package/dist/dist/Text.stories.js.map +0 -1
- package/dist/dist/TextArea.d.ts +0 -6
- package/dist/dist/TextArea.js +0 -13
- package/dist/dist/TextArea.js.map +0 -1
- package/dist/dist/TextArea.stories.d.ts +0 -12
- package/dist/dist/TextArea.stories.js +0 -21
- package/dist/dist/TextArea.stories.js.map +0 -1
- package/dist/dist/TextField.d.ts +0 -47
- package/dist/dist/TextField.js +0 -199
- package/dist/dist/TextField.js.map +0 -1
- package/dist/dist/TextField.stories.d.ts +0 -6
- package/dist/dist/TextField.stories.js +0 -15
- package/dist/dist/TextField.stories.js.map +0 -1
- package/dist/dist/TextFieldNumberActionSheet.d.ts +0 -5
- package/dist/dist/TextFieldNumberActionSheet.js +0 -24
- package/dist/dist/TextFieldNumberActionSheet.js.map +0 -1
- package/dist/dist/UnifiedScreens.d.ts +0 -2
- package/dist/dist/UnifiedScreens.js +0 -26
- package/dist/dist/UnifiedScreens.js.map +0 -1
- package/dist/dist/Unifier.d.ts +0 -131
- package/dist/dist/Unifier.js +0 -198
- package/dist/dist/Unifier.js.map +0 -1
- package/dist/dist/Utilities.d.ts +0 -51
- package/dist/dist/Utilities.js +0 -77
- package/dist/dist/Utilities.js.map +0 -1
- package/dist/dist/WithLabel.d.ts +0 -6
- package/dist/dist/WithLabel.js +0 -23
- package/dist/dist/WithLabel.js.map +0 -1
- package/dist/dist/index.d.ts +0 -43
- package/dist/dist/index.js +0 -49
- package/dist/dist/index.js.map +0 -1
package/dist/Unifier.js
CHANGED
|
@@ -126,13 +126,6 @@ class UnifierClass {
|
|
|
126
126
|
openUrl: async (url) => {
|
|
127
127
|
return Linking.openURL(url);
|
|
128
128
|
},
|
|
129
|
-
// keepAwake: (activate: boolean) => {
|
|
130
|
-
// if (activate) {
|
|
131
|
-
// activateKeepAwake();
|
|
132
|
-
// } else {
|
|
133
|
-
// deactivateKeepAwake();
|
|
134
|
-
// }
|
|
135
|
-
// },
|
|
136
129
|
};
|
|
137
130
|
this.storage = {
|
|
138
131
|
getItem: async (key, defaultValue) => {
|
|
@@ -193,8 +186,7 @@ class UnifierClass {
|
|
|
193
186
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30;
|
|
194
187
|
return Object.assign(Object.assign({}, DefaultTheme), {
|
|
195
188
|
// Custom per project
|
|
196
|
-
primaryLighter: ((_a = this._theme) === null || _a === void 0 ? void 0 : _a.primaryLighter) || ((_b = this._theme) === null || _b === void 0 ? void 0 : _b.primary) || DefaultTheme.primary, primaryLight: ((_c = this._theme) === null || _c === void 0 ? void 0 : _c.primaryLight) || ((_d = this._theme) === null || _d === void 0 ? void 0 : _d.primary) || DefaultTheme.primary, primary: ((_e = this._theme) === null || _e === void 0 ? void 0 : _e.primary) || ((_f = this._theme) === null || _f === void 0 ? void 0 : _f.primary) || DefaultTheme.primary, primaryDark: ((_g = this._theme) === null || _g === void 0 ? void 0 : _g.primaryDark) || ((_h = this._theme) === null || _h === void 0 ? void 0 : _h.primary) || DefaultTheme.primary, primaryDarker: ((_j = this._theme) === null || _j === void 0 ? void 0 : _j.primaryDarker) || ((_k = this._theme) === null || _k === void 0 ? void 0 : _k.primary) || DefaultTheme.primary, secondaryLighter: ((_l = this._theme) === null || _l === void 0 ? void 0 : _l.secondaryLighter) || ((_m = this._theme) === null || _m === void 0 ? void 0 : _m.secondary) || DefaultTheme.secondary, secondaryLight: ((_o = this._theme) === null || _o === void 0 ? void 0 : _o.secondaryLight) || ((_p = this._theme) === null || _p === void 0 ? void 0 : _p.secondary) || DefaultTheme.secondary, secondary: ((_q = this._theme) === null || _q === void 0 ? void 0 : _q.secondary) || ((_r = this._theme) === null || _r === void 0 ? void 0 : _r.secondary) || DefaultTheme.secondary, secondaryDark: ((_s = this._theme) === null || _s === void 0 ? void 0 : _s.secondaryDark) || ((_t = this._theme) === null || _t === void 0 ? void 0 : _t.secondary) || DefaultTheme.secondary, secondaryDarker: ((_u = this._theme) === null || _u === void 0 ? void 0 : _u.secondaryDarker) || ((_v = this._theme) === null || _v === void 0 ? void 0 : _v.secondary) || DefaultTheme.secondary, accentLighter: ((_w = this._theme) === null || _w === void 0 ? void 0 : _w.accentLighter) || ((_x = this._theme) === null || _x === void 0 ? void 0 : _x.accent) || DefaultTheme.accent, accentLight: ((_y = this._theme) === null || _y === void 0 ? void 0 : _y.accentLight) || ((_z = this._theme) === null || _z === void 0 ? void 0 : _z.accent) || DefaultTheme.accent, accent: ((_0 = this._theme) === null || _0 === void 0 ? void 0 : _0.accent) || ((_1 = this._theme) === null || _1 === void 0 ? void 0 : _1.accent) || DefaultTheme.accent, accentDark: ((_2 = this._theme) === null || _2 === void 0 ? void 0 : _2.accentDark) || ((_3 = this._theme) === null || _3 === void 0 ? void 0 : _3.accent) || DefaultTheme.accent, accentDarker: ((_4 = this._theme) === null || _4 === void 0 ? void 0 : _4.accentDarker) || ((_5 = this._theme) === null || _5 === void 0 ? void 0 : _5.accent) || DefaultTheme.accent, tertiaryLighter: ((_6 = this._theme) === null || _6 === void 0 ? void 0 : _6.tertiaryLighter) || ((_7 = this._theme) === null || _7 === void 0 ? void 0 : _7.accent) || DefaultTheme.accent, tertiaryLight: ((_8 = this._theme) === null || _8 === void 0 ? void 0 : _8.tertiaryLight) || ((_9 = this._theme) === null || _9 === void 0 ? void 0 : _9.accent) || DefaultTheme.accent, tertiary: ((_10 = this._theme) === null || _10 === void 0 ? void 0 : _10.tertiary) || ((_11 = this._theme) === null || _11 === void 0 ? void 0 : _11.accent) || DefaultTheme.accent, tertiaryDark: ((_12 = this._theme) === null || _12 === void 0 ? void 0 : _12.tertiaryDark) || ((_13 = this._theme) === null || _13 === void 0 ? void 0 : _13.accent) || DefaultTheme.accent, tertiaryDarker: ((_14 = this._theme) === null || _14 === void 0 ? void 0 : _14.tertiaryDarker) || ((_15 = this._theme) === null || _15 === void 0 ? void 0 : _15.accent) || DefaultTheme.accent, primaryFont: ((_16 = this._theme) === null || _16 === void 0 ? void 0 : _16.primaryFont) || DefaultTheme.primaryFont, primaryBoldFont: ((_17 = this._theme) === null || _17 === void 0 ? void 0 : _17.primaryBoldFont) || ((_18 = this._theme) === null || _18 === void 0 ? void 0 : _18.primaryFont) || DefaultTheme.primaryBoldFont, secondaryFont: ((_19 = this._theme) === null || _19 === void 0 ? void 0 : _19.secondaryFont) || ((_20 = this._theme) === null || _20 === void 0 ? void 0 : _20.primaryFont) || DefaultTheme.secondaryFont, secondaryBoldFont: ((_21 = this._theme) === null || _21 === void 0 ? void 0 : _21.secondaryBoldFont) ||
|
|
197
|
-
((_22 = this._theme) === null || _22 === void 0 ? void 0 : _22.primaryFont) ||
|
|
189
|
+
primaryLighter: ((_a = this._theme) === null || _a === void 0 ? void 0 : _a.primaryLighter) || ((_b = this._theme) === null || _b === void 0 ? void 0 : _b.primary) || DefaultTheme.primary, primaryLight: ((_c = this._theme) === null || _c === void 0 ? void 0 : _c.primaryLight) || ((_d = this._theme) === null || _d === void 0 ? void 0 : _d.primary) || DefaultTheme.primary, primary: ((_e = this._theme) === null || _e === void 0 ? void 0 : _e.primary) || ((_f = this._theme) === null || _f === void 0 ? void 0 : _f.primary) || DefaultTheme.primary, primaryDark: ((_g = this._theme) === null || _g === void 0 ? void 0 : _g.primaryDark) || ((_h = this._theme) === null || _h === void 0 ? void 0 : _h.primary) || DefaultTheme.primary, primaryDarker: ((_j = this._theme) === null || _j === void 0 ? void 0 : _j.primaryDarker) || ((_k = this._theme) === null || _k === void 0 ? void 0 : _k.primary) || DefaultTheme.primary, secondaryLighter: ((_l = this._theme) === null || _l === void 0 ? void 0 : _l.secondaryLighter) || ((_m = this._theme) === null || _m === void 0 ? void 0 : _m.secondary) || DefaultTheme.secondary, secondaryLight: ((_o = this._theme) === null || _o === void 0 ? void 0 : _o.secondaryLight) || ((_p = this._theme) === null || _p === void 0 ? void 0 : _p.secondary) || DefaultTheme.secondary, secondary: ((_q = this._theme) === null || _q === void 0 ? void 0 : _q.secondary) || ((_r = this._theme) === null || _r === void 0 ? void 0 : _r.secondary) || DefaultTheme.secondary, secondaryDark: ((_s = this._theme) === null || _s === void 0 ? void 0 : _s.secondaryDark) || ((_t = this._theme) === null || _t === void 0 ? void 0 : _t.secondary) || DefaultTheme.secondary, secondaryDarker: ((_u = this._theme) === null || _u === void 0 ? void 0 : _u.secondaryDarker) || ((_v = this._theme) === null || _v === void 0 ? void 0 : _v.secondary) || DefaultTheme.secondary, accentLighter: ((_w = this._theme) === null || _w === void 0 ? void 0 : _w.accentLighter) || ((_x = this._theme) === null || _x === void 0 ? void 0 : _x.accent) || DefaultTheme.accent, accentLight: ((_y = this._theme) === null || _y === void 0 ? void 0 : _y.accentLight) || ((_z = this._theme) === null || _z === void 0 ? void 0 : _z.accent) || DefaultTheme.accent, accent: ((_0 = this._theme) === null || _0 === void 0 ? void 0 : _0.accent) || ((_1 = this._theme) === null || _1 === void 0 ? void 0 : _1.accent) || DefaultTheme.accent, accentDark: ((_2 = this._theme) === null || _2 === void 0 ? void 0 : _2.accentDark) || ((_3 = this._theme) === null || _3 === void 0 ? void 0 : _3.accent) || DefaultTheme.accent, accentDarker: ((_4 = this._theme) === null || _4 === void 0 ? void 0 : _4.accentDarker) || ((_5 = this._theme) === null || _5 === void 0 ? void 0 : _5.accent) || DefaultTheme.accent, tertiaryLighter: ((_6 = this._theme) === null || _6 === void 0 ? void 0 : _6.tertiaryLighter) || ((_7 = this._theme) === null || _7 === void 0 ? void 0 : _7.accent) || DefaultTheme.accent, tertiaryLight: ((_8 = this._theme) === null || _8 === void 0 ? void 0 : _8.tertiaryLight) || ((_9 = this._theme) === null || _9 === void 0 ? void 0 : _9.accent) || DefaultTheme.accent, tertiary: ((_10 = this._theme) === null || _10 === void 0 ? void 0 : _10.tertiary) || ((_11 = this._theme) === null || _11 === void 0 ? void 0 : _11.accent) || DefaultTheme.accent, tertiaryDark: ((_12 = this._theme) === null || _12 === void 0 ? void 0 : _12.tertiaryDark) || ((_13 = this._theme) === null || _13 === void 0 ? void 0 : _13.accent) || DefaultTheme.accent, tertiaryDarker: ((_14 = this._theme) === null || _14 === void 0 ? void 0 : _14.tertiaryDarker) || ((_15 = this._theme) === null || _15 === void 0 ? void 0 : _15.accent) || DefaultTheme.accent, primaryFont: ((_16 = this._theme) === null || _16 === void 0 ? void 0 : _16.primaryFont) || DefaultTheme.primaryFont, primaryBoldFont: ((_17 = this._theme) === null || _17 === void 0 ? void 0 : _17.primaryBoldFont) || ((_18 = this._theme) === null || _18 === void 0 ? void 0 : _18.primaryFont) || DefaultTheme.primaryBoldFont, secondaryFont: ((_19 = this._theme) === null || _19 === void 0 ? void 0 : _19.secondaryFont) || ((_20 = this._theme) === null || _20 === void 0 ? void 0 : _20.primaryFont) || DefaultTheme.secondaryFont, secondaryBoldFont: ((_21 = this._theme) === null || _21 === void 0 ? void 0 : _21.secondaryBoldFont) || ((_22 = this._theme) === null || _22 === void 0 ? void 0 : _22.primaryFont) ||
|
|
198
190
|
DefaultTheme.secondaryBoldFont, buttonFont: ((_23 = this._theme) === null || _23 === void 0 ? void 0 : _23.buttonFont) || ((_24 = this._theme) === null || _24 === void 0 ? void 0 : _24.primaryFont) || DefaultTheme.buttonFont, accentFont: ((_25 = this._theme) === null || _25 === void 0 ? void 0 : _25.accentFont) || ((_26 = this._theme) === null || _26 === void 0 ? void 0 : _26.primaryFont) || DefaultTheme.accentFont, accentBoldFont: ((_27 = this._theme) === null || _27 === void 0 ? void 0 : _27.accentBoldFont) || ((_28 = this._theme) === null || _28 === void 0 ? void 0 : _28.primaryFont) || DefaultTheme.accentBoldFont, titleFont: ((_29 = this._theme) === null || _29 === void 0 ? void 0 : _29.titleFont) || ((_30 = this._theme) === null || _30 === void 0 ? void 0 : _30.primaryFont) || DefaultTheme.titleFont });
|
|
199
191
|
}
|
|
200
192
|
}
|
package/dist/Unifier.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Unifier.js","sourceRoot":"","sources":["../src/Unifier.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,yDAAyD;AAEzD,OAAO,YAAY,MAAM,2CAA2C,CAAC;AACrE,OAAO,EAAC,SAAS,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAC,MAAM,cAAc,CAAC;AACjF,OAAO,yBAAyB,MAAM,8BAA8B,CAAC;AAGrE,OAAO,EAAC,kBAAkB,EAAC,MAAM,eAAe,CAAC;AAEjD,MAAM,YAAY,GAAG,QAAQ,CAAC;AAC9B,MAAM,iBAAiB,GAAG,QAAQ,CA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AAC;AAEzD,MAAM,CAAC,MAAM,OAAO,GAAG,IAAI,YAAY,EAAE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ferns-ui",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"local": "tsc-watch --onSuccess \"cp -a dist/* ../totum/node_modules/react-unifier/dist\"",
|
|
8
|
-
"lint": "eslint
|
|
8
|
+
"lint": "eslint \"src/**/*.ts*\"",
|
|
9
|
+
"lintfix": "eslint --fix \"src/**/*.ts*\"",
|
|
9
10
|
"build": "tsc",
|
|
10
11
|
"dev": "tsc -w"
|
|
11
12
|
},
|
|
@@ -115,39 +116,39 @@
|
|
|
115
116
|
"@types/react": "17.0.44"
|
|
116
117
|
},
|
|
117
118
|
"dependencies": {
|
|
118
|
-
"tsc-watch": "^5.0.
|
|
119
|
+
"tsc-watch": "^5.0.3"
|
|
119
120
|
},
|
|
120
121
|
"devDependencies": {
|
|
121
|
-
"@
|
|
122
|
-
"
|
|
123
|
-
"@expo/vector-icons": "^12.0.0",
|
|
124
|
-
"@react-native-async-storage/async-storage": "^1.17.3",
|
|
122
|
+
"@expo/vector-icons": "^13.0.0",
|
|
123
|
+
"@react-native-async-storage/async-storage": "^1.17.4",
|
|
125
124
|
"@react-native-community/blur": "^3.6.0",
|
|
126
|
-
"@react-native-community/datetimepicker": "^
|
|
125
|
+
"@react-native-community/datetimepicker": "^6.1.3",
|
|
127
126
|
"@react-native-picker/picker": "^2.2.1",
|
|
128
|
-
"@sentry/browser": "^
|
|
129
|
-
"@sentry/react": "^
|
|
130
|
-
"@sentry/react-native": "^
|
|
131
|
-
"@types/
|
|
132
|
-
"@
|
|
133
|
-
"@typescript-eslint/
|
|
134
|
-
"eslint": "^
|
|
135
|
-
"eslint
|
|
136
|
-
"eslint-
|
|
127
|
+
"@sentry/browser": "^6.19.7",
|
|
128
|
+
"@sentry/react": "^6.19.7",
|
|
129
|
+
"@sentry/react-native": "^3.4.2",
|
|
130
|
+
"@types/lodash": "^4.14.182",
|
|
131
|
+
"@types/react-native": "^0.67.7",
|
|
132
|
+
"@typescript-eslint/eslint-plugin": "^5.23.0",
|
|
133
|
+
"@typescript-eslint/parser": "^5.23.0",
|
|
134
|
+
"eslint": "^8.15.0",
|
|
135
|
+
"eslint-config-ferns": "^0.3.1",
|
|
136
|
+
"eslint-config-prettier": "^8.5.0",
|
|
137
|
+
"eslint-plugin-import": "^2.26.0",
|
|
137
138
|
"eslint-plugin-lodash": "^7.1.0",
|
|
138
|
-
"eslint-plugin-prettier": "^
|
|
139
|
-
"eslint-plugin-react": "^7.
|
|
140
|
-
"eslint-plugin-react-native": "^
|
|
139
|
+
"eslint-plugin-prettier": "^4.0.0",
|
|
140
|
+
"eslint-plugin-react": "^7.29.4",
|
|
141
|
+
"eslint-plugin-react-native": "^4.0.0",
|
|
141
142
|
"eslint-plugin-simple-import-sort": "^7.0.0",
|
|
142
|
-
"expo-font": "^10.0
|
|
143
|
+
"expo-font": "^10.1.0",
|
|
143
144
|
"lodash": "^4.17.21",
|
|
144
145
|
"mixpanel-browser": "^2.38.0",
|
|
145
146
|
"moment-timezone": "^0.5.34",
|
|
146
|
-
"prettier": "^2.
|
|
147
|
+
"prettier": "^2.6.2",
|
|
147
148
|
"react": "^17.0.0",
|
|
148
149
|
"react-app-polyfill": "^1.0.6",
|
|
149
150
|
"react-date-picker": "^7.10.0",
|
|
150
|
-
"react-dev-utils": "^
|
|
151
|
+
"react-dev-utils": "^11.0.4",
|
|
151
152
|
"react-dom": "17.0.2",
|
|
152
153
|
"react-native": "^0.64.3",
|
|
153
154
|
"react-native-gesture-handler": "^1.6.1",
|
|
@@ -161,7 +162,7 @@
|
|
|
161
162
|
"react-native-svg": "^12.1.0",
|
|
162
163
|
"react-router": "^5.2.0",
|
|
163
164
|
"react-router-dom": "^5.2.0",
|
|
164
|
-
"typescript": "
|
|
165
|
+
"typescript": "~4.1.5"
|
|
165
166
|
},
|
|
166
167
|
"peerDependencies": {
|
|
167
168
|
"@expo/vector-icons": "^12.0.0",
|
|
@@ -179,7 +180,7 @@
|
|
|
179
180
|
"react": "^17.0.0",
|
|
180
181
|
"react-app-polyfill": "^1.0.6",
|
|
181
182
|
"react-date-picker": "^7.10.0",
|
|
182
|
-
"react-dev-utils": "^
|
|
183
|
+
"react-dev-utils": "^11.0.4",
|
|
183
184
|
"react-dom": "17.0.2",
|
|
184
185
|
"react-native": "^0.64.3",
|
|
185
186
|
"react-native-gesture-handler": "^1.6.1",
|
package/src/Field.tsx
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import isDate from "lodash/isDate";
|
|
2
2
|
import isNumber from "lodash/isNumber";
|
|
3
3
|
import moment from "moment-timezone";
|
|
4
|
-
import React from "react";
|
|
4
|
+
import React, {useState} from "react";
|
|
5
5
|
|
|
6
6
|
import {Box} from "./Box";
|
|
7
7
|
import {FieldProps, TextFieldType} from "./Common";
|
|
@@ -15,60 +15,58 @@ interface State {
|
|
|
15
15
|
value: any;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
/**
|
|
19
|
+
* Field is a fully uncontrolled component for creating various inputs. Fully uncontrolled means Field manages its own
|
|
20
|
+
* state for the TextFields/Switches/etc, not the parent component. When values are updated, Field will pass the data to
|
|
21
|
+
* the parent through the handleChange prop. You can set an initialValue, but you should not update initialValue
|
|
22
|
+
* this prop with the result of handleChange.
|
|
23
|
+
*
|
|
24
|
+
* Note: You MUST set a key={} prop for this component, otherwise you may wind up with stale data. Just changing
|
|
25
|
+
* initialValue will not work.
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
28
|
+
export function Field(props: FieldProps) {
|
|
29
|
+
const [value, setValue] = useState(props.initialValue || "");
|
|
23
30
|
|
|
24
|
-
|
|
25
|
-
if (
|
|
26
|
-
|
|
31
|
+
const handleChange = (newValue: string) => {
|
|
32
|
+
if (props.type === "currency") {
|
|
33
|
+
newValue = newValue.replace("$", "");
|
|
34
|
+
} else if (props.type === "percent") {
|
|
35
|
+
newValue = newValue.replace("%", "");
|
|
27
36
|
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
if (this.props.type === "currency") {
|
|
32
|
-
value = value.replace("$", "");
|
|
33
|
-
} else if (this.props.type === "percent") {
|
|
34
|
-
value = value.replace("%", "");
|
|
35
|
-
}
|
|
36
|
-
this.setState({value});
|
|
37
|
-
if (this.props.handleChange) {
|
|
38
|
-
this.props.handleChange(this.props.name, value);
|
|
37
|
+
setValue(newValue);
|
|
38
|
+
if (props.handleChange) {
|
|
39
|
+
props.handleChange(props.name, newValue);
|
|
39
40
|
}
|
|
40
41
|
};
|
|
41
42
|
|
|
42
|
-
handleSwitchChange = (
|
|
43
|
-
|
|
44
|
-
if (
|
|
45
|
-
|
|
43
|
+
const handleSwitchChange = (switchValue: boolean) => {
|
|
44
|
+
setValue(switchValue);
|
|
45
|
+
if (props.handleChange) {
|
|
46
|
+
props.handleChange(props.name, switchValue);
|
|
46
47
|
}
|
|
47
48
|
};
|
|
48
49
|
|
|
49
|
-
validate = () => {
|
|
50
|
-
// console.log("VALIDATE",
|
|
51
|
-
if (
|
|
50
|
+
const validate = () => {
|
|
51
|
+
// console.log("VALIDATE", props.validate && props.validate(value));
|
|
52
|
+
if (props.validate && !props.validate(value)) {
|
|
52
53
|
return false;
|
|
53
54
|
}
|
|
54
|
-
switch (
|
|
55
|
+
switch (props.type) {
|
|
55
56
|
case "boolean":
|
|
56
57
|
return true;
|
|
57
58
|
case "currency":
|
|
58
59
|
return true;
|
|
59
60
|
case "date":
|
|
60
|
-
return !
|
|
61
|
+
return !value || isDate(value);
|
|
61
62
|
case "email":
|
|
62
|
-
return (
|
|
63
|
-
!this.state.value ||
|
|
64
|
-
(this.state.value.search("@") > -1 && this.state.value.search(".") > -1)
|
|
65
|
-
);
|
|
63
|
+
return !value || (value.search("@") > -1 && value.search(".") > -1);
|
|
66
64
|
case "number":
|
|
67
|
-
return !
|
|
65
|
+
return !value || isNumber(value);
|
|
68
66
|
case "password":
|
|
69
67
|
return true;
|
|
70
68
|
case "percent":
|
|
71
|
-
return !
|
|
69
|
+
return !value || isNumber(value.replace("%", ""));
|
|
72
70
|
case "select":
|
|
73
71
|
return true;
|
|
74
72
|
case "text":
|
|
@@ -83,64 +81,62 @@ export class Field extends React.Component<FieldProps, State> {
|
|
|
83
81
|
}
|
|
84
82
|
};
|
|
85
83
|
|
|
86
|
-
renderField() {
|
|
87
|
-
if (
|
|
88
|
-
if (!
|
|
84
|
+
const renderField = () => {
|
|
85
|
+
if (props.type === "select") {
|
|
86
|
+
if (!props.options) {
|
|
89
87
|
console.error("Field with type=select require options");
|
|
90
88
|
return null;
|
|
91
89
|
}
|
|
92
90
|
return (
|
|
93
91
|
<SelectList
|
|
94
|
-
disabled={
|
|
95
|
-
id={
|
|
96
|
-
options={
|
|
97
|
-
value={
|
|
98
|
-
onChange={
|
|
92
|
+
disabled={props.disabled}
|
|
93
|
+
id={props.name}
|
|
94
|
+
options={props.options}
|
|
95
|
+
value={value}
|
|
96
|
+
onChange={handleChange}
|
|
99
97
|
/>
|
|
100
98
|
);
|
|
101
|
-
} else if (
|
|
99
|
+
} else if (props.type === "textarea") {
|
|
102
100
|
return (
|
|
103
101
|
<TextArea
|
|
104
|
-
disabled={
|
|
105
|
-
id={
|
|
106
|
-
placeholder={
|
|
107
|
-
rows={
|
|
108
|
-
value={String(
|
|
109
|
-
onChange={(
|
|
102
|
+
disabled={props.disabled}
|
|
103
|
+
id={props.name}
|
|
104
|
+
placeholder={props.placeholder}
|
|
105
|
+
rows={props.rows}
|
|
106
|
+
value={String(value)}
|
|
107
|
+
onChange={(result) => handleChange(result.value)}
|
|
110
108
|
/>
|
|
111
109
|
);
|
|
112
|
-
} else if (
|
|
110
|
+
} else if (props.type === "boolean") {
|
|
113
111
|
return (
|
|
114
112
|
<Switch
|
|
115
|
-
disabled={
|
|
116
|
-
id={
|
|
117
|
-
name={
|
|
118
|
-
switched={Boolean(
|
|
119
|
-
onChange={(result) =>
|
|
113
|
+
disabled={props.disabled}
|
|
114
|
+
id={props.name}
|
|
115
|
+
name={props.name}
|
|
116
|
+
switched={Boolean(value)}
|
|
117
|
+
onChange={(result) => handleSwitchChange(result)}
|
|
120
118
|
/>
|
|
121
119
|
);
|
|
122
|
-
} else if (
|
|
123
|
-
const
|
|
124
|
-
? moment(this.state.value.seconds * 1000)
|
|
125
|
-
: moment(this.state.value);
|
|
120
|
+
} else if (props.type === "date") {
|
|
121
|
+
const date = value.seconds ? moment(value.seconds * 1000) : moment(value);
|
|
126
122
|
return (
|
|
127
123
|
<TextField
|
|
128
124
|
disabled
|
|
129
|
-
id={
|
|
130
|
-
placeholder={
|
|
125
|
+
id={props.name}
|
|
126
|
+
placeholder={props.placeholder}
|
|
131
127
|
type="text"
|
|
132
128
|
// TODO: allow editing with a date picker
|
|
133
|
-
value={
|
|
134
|
-
onChange={(result) =>
|
|
129
|
+
value={date.format("MM/DD/YYYY HH:mmA")}
|
|
130
|
+
onChange={(result) => handleChange(result.value)}
|
|
135
131
|
/>
|
|
136
132
|
);
|
|
137
133
|
} else {
|
|
138
134
|
let type: TextFieldType = "text";
|
|
139
135
|
// Number is supported differently because we need fractional numbers and they don't work
|
|
140
136
|
// well on iOS.
|
|
141
|
-
if (
|
|
142
|
-
type =
|
|
143
|
-
} else if (
|
|
137
|
+
if (props.type && ["date", "email", "password", "url"].indexOf(props.type) > -1) {
|
|
138
|
+
type = props.type as TextFieldType;
|
|
139
|
+
} else if (props.type === "percent" || props.type === "currency") {
|
|
144
140
|
type = "text";
|
|
145
141
|
}
|
|
146
142
|
let autoComplete: "on" | "current-password" | "username" = "on";
|
|
@@ -149,46 +145,43 @@ export class Field extends React.Component<FieldProps, State> {
|
|
|
149
145
|
} else if (type === "email") {
|
|
150
146
|
autoComplete = "username";
|
|
151
147
|
}
|
|
152
|
-
const
|
|
153
|
-
// if (
|
|
154
|
-
// value = `${Number(
|
|
155
|
-
// } else if (
|
|
148
|
+
const stringValue = String(value);
|
|
149
|
+
// if (props.type === "percent") {
|
|
150
|
+
// value = `${Number(value).toFixed(0)}%`;
|
|
151
|
+
// } else if (props.type === "currency") {
|
|
156
152
|
// value = `$${Number(value).toFixed(2)}`;
|
|
157
153
|
// }
|
|
158
154
|
// console.log("VAL", value);
|
|
159
155
|
return (
|
|
160
156
|
<TextField
|
|
161
157
|
autoComplete={autoComplete}
|
|
162
|
-
disabled={
|
|
163
|
-
id={
|
|
164
|
-
placeholder={
|
|
158
|
+
disabled={props.disabled}
|
|
159
|
+
id={props.name}
|
|
160
|
+
placeholder={props.placeholder}
|
|
165
161
|
type={type as "date" | "email" | "number" | "password" | "text" | "url"}
|
|
166
|
-
value={
|
|
167
|
-
onChange={(result) =>
|
|
162
|
+
value={stringValue}
|
|
163
|
+
onChange={(result) => handleChange(result.value)}
|
|
168
164
|
/>
|
|
169
165
|
);
|
|
170
166
|
}
|
|
171
|
-
}
|
|
167
|
+
};
|
|
172
168
|
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
</Box>
|
|
192
|
-
);
|
|
193
|
-
}
|
|
169
|
+
const children = renderField();
|
|
170
|
+
const {errorMessage, errorMessageColor, helperText, helperTextColor, label, labelColor} = props;
|
|
171
|
+
return (
|
|
172
|
+
<Box marginBottom={5}>
|
|
173
|
+
<FieldWithLabels
|
|
174
|
+
{...{
|
|
175
|
+
errorMessage,
|
|
176
|
+
errorMessageColor,
|
|
177
|
+
helperText,
|
|
178
|
+
helperTextColor,
|
|
179
|
+
label,
|
|
180
|
+
labelColor,
|
|
181
|
+
}}
|
|
182
|
+
>
|
|
183
|
+
{children}
|
|
184
|
+
</FieldWithLabels>
|
|
185
|
+
</Box>
|
|
186
|
+
);
|
|
194
187
|
}
|
package/dist/Banner.stories.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/Banner.stories.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Box } from "./Box";
|
|
2
|
-
import { Banner } from "./Banner";
|
|
3
|
-
import React from "react";
|
|
4
|
-
import { storiesOf } from "@storybook/react-native";
|
|
5
|
-
storiesOf("Banner", module)
|
|
6
|
-
.add("Plain banner", () => (React.createElement(Box, { width: "100%", height: "100%", display: "flex", direction: "column" },
|
|
7
|
-
React.createElement(Banner, { id: "banner", text: "When you click this banner, it dismisses", subtext: "And in a real app, it would stay dismissed", color: "primary", textColor: "white" }))))
|
|
8
|
-
.add("Shape banner", () => (React.createElement(Box, { width: "100%", height: "100%", display: "flex", direction: "column" },
|
|
9
|
-
React.createElement(Box, { paddingY: 2, width: "100%" },
|
|
10
|
-
React.createElement(Banner, { id: "banner", text: "Banners can have multiple shapes like Boxes", subtext: "Here's a pill.", color: "primary", textColor: "white", shape: "pill" })),
|
|
11
|
-
React.createElement(Box, { paddingY: 2, width: "100%" },
|
|
12
|
-
React.createElement(Banner, { id: "banner", text: "And a rounded banner", color: "secondary", textColor: "white", shape: 3 })))));
|
|
13
|
-
//# sourceMappingURL=Banner.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Banner.stories.js","sourceRoot":"","sources":["../unifier/Banner.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,GAAG,EAAC,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,MAAM,EAAC,MAAM,UAAU,CAAC;AAEhC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B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Box";
|
|
3
|
-
import { storiesOf } from "@storybook/react-native";
|
|
4
|
-
import { Text } from "./Text";
|
|
5
|
-
import { StorybookContainer } from "./StorybookContainer";
|
|
6
|
-
const colors = [
|
|
7
|
-
"primary",
|
|
8
|
-
"secondary",
|
|
9
|
-
"tertiary",
|
|
10
|
-
"accent",
|
|
11
|
-
"blue",
|
|
12
|
-
"darkGray",
|
|
13
|
-
"eggplant",
|
|
14
|
-
"gray",
|
|
15
|
-
"green",
|
|
16
|
-
"lightGray",
|
|
17
|
-
"maroon",
|
|
18
|
-
"midnight",
|
|
19
|
-
"navy",
|
|
20
|
-
"olive",
|
|
21
|
-
"orange",
|
|
22
|
-
"orchid",
|
|
23
|
-
"pine",
|
|
24
|
-
"purple",
|
|
25
|
-
"red",
|
|
26
|
-
"watermelon",
|
|
27
|
-
"white",
|
|
28
|
-
"neutral900",
|
|
29
|
-
"neutral200",
|
|
30
|
-
"neutral70",
|
|
31
|
-
"neutral10",
|
|
32
|
-
];
|
|
33
|
-
storiesOf("Box", module)
|
|
34
|
-
.add("FlexBox", () => (React.createElement(StorybookContainer, null,
|
|
35
|
-
React.createElement(Box, { display: "flex", justifyContent: "center", alignItems: "center", width: 50, height: 50, rounding: "circle", color: "blue", marginRight: 2 },
|
|
36
|
-
React.createElement(Text, { size: "lg" }, "JG")),
|
|
37
|
-
React.createElement(Box, { paddingX: 2, direction: "column" },
|
|
38
|
-
React.createElement(Text, { weight: "bold" }, "Josh Gachnang"),
|
|
39
|
-
React.createElement(Text, null, "joined 2 years ago")))))
|
|
40
|
-
.add("Box Colors", () => (React.createElement(StorybookContainer, null, colors.map((c) => (React.createElement(Box, { key: c, display: "flex", direction: "column" },
|
|
41
|
-
React.createElement(Box, { marginBottom: 2 },
|
|
42
|
-
React.createElement(Text, { align: "center" }, c)),
|
|
43
|
-
React.createElement(Box, { key: c, color: c, rounding: "circle", height: 50, width: 50 },
|
|
44
|
-
React.createElement(Text, null, " "))))))));
|
|
45
|
-
//# sourceMappingURL=Box.stories.js.map
|
package/dist/Box.stories.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Box.stories.js","sourceRoot":"","sources":["../unifier/Box.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,GAAG,EAAC,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAC,SAAS,EAAC,MAAM,yBAAyB,CAAC;AAClD,OAAO,EAAC,IAAI,EAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAC,kBAAkB,EAAC,MAAM,sBAAsB,CAAC;AAExD,MAAM,MAAM,GAAgB;IAC1B,SAAS;IACT,WAAW;IACX,UAAU;IACV,QAAQ;IACR,MAAM;IACN,UAAU;IACV,UAAU;IACV,MAAM;IACN,OAAO;IACP,WAAW;IACX,QAAQ;IACR,UAAU;IACV,MAAM;IACN,OAAO;IACP,QAAQ;IACR,QAAQ;IACR,MAAM;IACN,QAAQ;IACR,KAAK;IACL,YAAY;IACZ,OAAO;IACP,YAAY;IACZ,YAAY;IACZ,WAAW;IACX,WAAW;CACZ,CAAC;AAEF,SAAS,CAAC,KAAK,EAAE,MAAM,CAAC;KACrB,GAAG,CAAC,SAAS,EAAE,GAAG,EAAE,CAAC,CACpB,oBAAC,kBAAkB;IACjB,oBAAC,GAAG,IACF,OAAO,EAAC,MAAM,EACd,cAAc,EAAC,QAAQ,EACvB,UAAU,EAAC,QAAQ,EACnB,KAAK,EAAE,EAAE,EACT,MAAM,EAAE,EAAE,EACV,QAAQ,EAAC,QAAQ,EACjB,KAAK,EAAC,MAAM,EACZ,WAAW,EAAE,CAAC;QAEd,oBAAC,IAAI,IAAC,IAAI,EAAC,IAAI,SAAU,CACrB;IACN,oBAAC,GAAG,IAAC,QAAQ,EAAE,CAAC,EAAE,SAAS,EAAC,QAAQ;QAClC,oBAAC,IAAI,IAAC,MAAM,EAAC,MAAM,oBAAqB;QACxC,oBAAC,IAAI,6BAA0B,CAC3B,CACa,CACtB,CAAC;KACD,GAAG,CAAC,YAAY,EAAE,GAAG,EAAE,CAAC,CACvB,oBAAC,kBAAkB,QAChB,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CACjB,oBAAC,GAAG,IAAC,GAAG,EAAE,CAAC,EAAE,OAAO,EAAC,MAAM,EAAC,SAAS,EAAC,QAAQ;IAC5C,oBAAC,GAAG,IAAC,YAAY,EAAE,CAAC;QAClB,oBAAC,IAAI,IAAC,KAAK,EAAC,QAAQ,IAAE,CAAC,CAAQ,CAC3B;IACN,oBAAC,GAAG,IAAC,GAAG,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAC,QAAQ,EAAC,MAAM,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE;QAC5D,oBAAC,IAAI,YAAS,CACV,CACF,CACP,CAAC,CACiB,CACtB,CAAC,CAAC"}
|
package/dist/Button.stories.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const Primary: any;
|
package/dist/Button.stories.js
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { action } from "@storybook/addon-actions";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { Button } from "./Button";
|
|
4
|
-
import { storiesOf } from "@storybook/react-native";
|
|
5
|
-
import { Box } from "./Box";
|
|
6
|
-
import { StorybookContainer } from "./StorybookContainer";
|
|
7
|
-
function allColorButtons(props) {
|
|
8
|
-
return (React.createElement(StorybookContainer, null,
|
|
9
|
-
React.createElement(Box, { paddingY: 1 },
|
|
10
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Default" }, props))),
|
|
11
|
-
React.createElement(Box, { paddingY: 1 },
|
|
12
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Primary", color: "primary" }, props))),
|
|
13
|
-
React.createElement(Box, { paddingY: 1 },
|
|
14
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Secondary", color: "secondary" }, props))),
|
|
15
|
-
React.createElement(Box, { paddingY: 1 },
|
|
16
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Tertiary", color: "tertiary" }, props))),
|
|
17
|
-
React.createElement(Box, { paddingY: 1 },
|
|
18
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Accent", color: "accent" }, props))),
|
|
19
|
-
React.createElement(Box, { paddingY: 1 },
|
|
20
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Red", color: "red" }, props))),
|
|
21
|
-
React.createElement(Box, { paddingY: 1 },
|
|
22
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Dark Gray", color: "darkGray" }, props))),
|
|
23
|
-
React.createElement(Box, { paddingY: 1 },
|
|
24
|
-
React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Gray", color: "gray" }, props)))));
|
|
25
|
-
}
|
|
26
|
-
storiesOf("Button", module)
|
|
27
|
-
.add("Colors", () => allColorButtons({}))
|
|
28
|
-
.add("Loading", () => allColorButtons({ loading: true }))
|
|
29
|
-
.add("Ghost", () => allColorButtons({ type: "ghost" }))
|
|
30
|
-
.add("Outline", () => allColorButtons({ type: "outline" }));
|
|
31
|
-
const Template = (args) => React.createElement(Button, Object.assign({ onClick: action("clicked"), text: "Button" }, args));
|
|
32
|
-
export const Primary = Template.bind({});
|
|
33
|
-
Primary.args = {
|
|
34
|
-
size: "md",
|
|
35
|
-
color: "primary",
|
|
36
|
-
text: "PRIMARY",
|
|
37
|
-
type: "solid",
|
|
38
|
-
inline: false,
|
|
39
|
-
disabled: false,
|
|
40
|
-
};
|
|
41
|
-
//# sourceMappingURL=Button.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Button.stories.js","sourceRoot":"","sources":["../unifier/Button.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAC,MAAM,0BAA0B,CAAC;AAChD,OAAO,KAAK,MAAM,OAAO,CAA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,EAAE,SAAS;IACf,IAAI,EAAE,OAAO;IACb,MAAM,EAAE,KAAK;IACb,QAAQ,EAAE,KAAK;CAChB,CAAC"}
|
package/dist/Card.stories.d.ts
DELETED
package/dist/Card.stories.js
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Box } from "./Box";
|
|
3
|
-
import { Card } from "./Card";
|
|
4
|
-
import { storiesOf } from "@storybook/react-native";
|
|
5
|
-
export default {
|
|
6
|
-
title: "Card",
|
|
7
|
-
component: Card,
|
|
8
|
-
};
|
|
9
|
-
storiesOf("Card", module).add("Plain", () => (React.createElement(Box, { width: "100%", height: "100%", display: "flex", direction: "column", color: "lightGray", padding: 12 },
|
|
10
|
-
React.createElement(Card, null,
|
|
11
|
-
React.createElement(Box, { display: "flex", direction: "row", alignItems: "center" },
|
|
12
|
-
React.createElement(Box, { display: "flex", justifyContent: "center", alignItems: "center", width: 50, height: 50, rounding: "circle", color: "blue", marginRight: 2 },
|
|
13
|
-
React.createElement("h2", null, "JG")),
|
|
14
|
-
React.createElement(Box, { paddingX: 2, direction: "column" },
|
|
15
|
-
React.createElement("div", null,
|
|
16
|
-
React.createElement("b", null, "Josh Gachnang")),
|
|
17
|
-
React.createElement("div", null, "joined 2 years ago")))))));
|
|
18
|
-
//# sourceMappingURL=Card.stories.js.map
|
package/dist/Card.stories.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Card.stories.js","sourceRoot":"","sources":["../unifier/Card.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,GAAG,EAAC,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAC,IAAI,EAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAC,SAAS,EAAC,MAAM,yBAAyB,CAAC;AAElD,eAAe;IACb,KAAK,EAAE,MAAM;IACb,SAAS,EAAE,IAAI;CAChB,CAAC;AAEF,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,OAAO,EAAE,GAAG,EAAE,CAAC,CAC3C,oBAAC,GAAG,IAAC,KAAK,EAAC,MAAM,EAAC,MAAM,EAAC,MAAM,EAAC,OAAO,EAAC,MAAM,EAAC,SAAS,EAAC,QAAQ,EAAC,KAAK,EAAC,WAAW,EAAC,OAAO,EAAE,EAAE;IAC7F,oBAAC,IAAI;QACH,oBAAC,GAAG,IAAC,OAAO,EAAC,MAAM,EAAC,SAAS,EAAC,KAAK,EAAC,UAAU,EAAC,QAAQ;YACrD,oBAAC,GAAG,IACF,OAAO,EAAC,MAAM,EACd,cAAc,EAAC,QAAQ,EACvB,UAAU,EAAC,QAAQ,EACnB,KAAK,EAAE,EAAE,EACT,MAAM,EAAE,EAAE,EACV,QAAQ,EAAC,QAAQ,EACjB,KAAK,EAAC,MAAM,EACZ,WAAW,EAAE,CAAC;gBAEd,qCAAW,CACP;YACN,oBAAC,GAAG,IAAC,QAAQ,EAAE,CAAC,EAAE,SAAS,EAAC,QAAQ;gBAClC;oBACE,+CAAoB,CAChB;gBACN,sDAA6B,CACzB,CACF,CACD,CACH,CACP,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|