@draftbit/core 43.7.2-49b1d4.1 → 43.7.2-5b80c5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/module/components/AnimatedCircularProgress.js +10 -2
- package/lib/module/components/AnimatedCircularProgress.js.map +1 -1
- package/lib/module/components/AvatarEdit.js +16 -5
- package/lib/module/components/AvatarEdit.js.map +1 -1
- package/lib/module/components/CardContainer.js +14 -5
- package/lib/module/components/CardContainer.js.map +1 -1
- package/lib/module/components/CardContainerShortImage.js +16 -5
- package/lib/module/components/CardContainerShortImage.js.map +1 -1
- package/lib/module/components/Checkbox/CheckboxGroupRow.js +22 -6
- package/lib/module/components/Checkbox/CheckboxGroupRow.js.map +1 -1
- package/lib/module/components/DeprecatedFAB.js +19 -4
- package/lib/module/components/DeprecatedFAB.js.map +1 -1
- package/lib/module/components/Divider.js +16 -2
- package/lib/module/components/Divider.js.map +1 -1
- package/lib/module/components/FormRow.js +17 -4
- package/lib/module/components/FormRow.js.map +1 -1
- package/lib/module/components/Header.js.map +1 -1
- package/lib/module/components/Image.js +18 -3
- package/lib/module/components/Image.js.map +1 -1
- package/lib/module/components/Justification.js +2 -2
- package/lib/module/components/Justification.js.map +1 -1
- package/lib/module/components/Layout.js +40 -21
- package/lib/module/components/Layout.js.map +1 -1
- package/lib/module/components/NumberInput.js +12 -2
- package/lib/module/components/NumberInput.js.map +1 -1
- package/lib/module/components/Portal/Portal.js +1 -1
- package/lib/module/components/Portal/Portal.js.map +1 -1
- package/lib/module/components/Portal/PortalConsumer.js.map +1 -1
- package/lib/module/components/ProgressIndicator.js.map +1 -1
- package/lib/module/components/RadioButton/RadioButton.js +14 -3
- package/lib/module/components/RadioButton/RadioButton.js.map +1 -1
- package/lib/module/components/Row.js.map +1 -1
- package/lib/module/components/StepIndicator.js.map +1 -1
- package/lib/module/components/Touchable.js +16 -3
- package/lib/module/components/Touchable.js.map +1 -1
- package/lib/module/components/useAuthState.js.map +1 -1
- package/lib/module/mappings/ActionSheetItem.js.map +1 -1
- package/lib/module/mappings/CardContainerShortImage.js.map +1 -1
- package/lib/module/mappings/CircleImage.js.map +1 -1
- package/lib/module/mappings/Divider.js.map +1 -1
- package/lib/module/mappings/Fetch.js.map +1 -1
- package/lib/module/mappings/HeaderOverline.js.map +1 -1
- package/lib/module/mappings/IconButton.js.map +1 -1
- package/lib/module/mappings/Picker.js.map +1 -1
- package/lib/module/mappings/StarRating.js +6 -2
- package/lib/module/mappings/StarRating.js.map +1 -1
- package/lib/module/mappings/Swiper.js.map +1 -1
- package/lib/module/mappings/ToggleButton.js.map +1 -1
- package/lib/module/utilities.js.map +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["utilities.
|
|
1
|
+
{"version":3,"sources":["utilities.js"],"names":["StyleSheet","isString","isNumber","extractStyles","style","color","fontFamily","fontWeight","fontSize","lineHeight","letterSpacing","textTransform","textAlign","textDecorationLine","textDecorationColor","textDecorationStyle","viewStyles","flatten","textStyles","applyStyles","baseStyles","stylesToApply","flattenedStyles","key","value","Object","entries","getValueForRadioButton","String","Error"],"mappings":"AAAA,SAASA,UAAT,QAA2B,cAA3B;AACA,SAASC,QAAT,EAAmBC,QAAnB,QAAmC,QAAnC;AACA,OAAO,SAASC,aAAT,CAAuBC,KAAvB,EAA8B;AACjC,QAAM;AAAEC,IAAAA,KAAF;AAASC,IAAAA,UAAT;AAAqBC,IAAAA,UAArB;AAAiCC,IAAAA,QAAjC;AAA2CC,IAAAA,UAA3C;AAAuDC,IAAAA,aAAvD;AAAsEC,IAAAA,aAAtE;AAAqFC,IAAAA,SAArF;AAAgGC,IAAAA,kBAAhG;AAAoHC,IAAAA,mBAApH;AAAyIC,IAAAA,mBAAzI;AAA8J,OAAGC;AAAjK,MAAgLhB,UAAU,CAACiB,OAAX,CAAmBb,KAAK,IAAI,EAA5B,CAAtL;AACA,QAAMc,UAAU,GAAG;AACfb,IAAAA,KADe;AAEfC,IAAAA,UAFe;AAGfC,IAAAA,UAHe;AAIfC,IAAAA,QAJe;AAKfC,IAAAA,UALe;AAMfC,IAAAA,aANe;AAOfC,IAAAA,aAPe;AAQfC,IAAAA,SARe;AASfC,IAAAA,kBATe;AAUfC,IAAAA,mBAVe;AAWfC,IAAAA;AAXe,GAAnB;AAaA,SAAO;AAAEC,IAAAA,UAAF;AAAcE,IAAAA;AAAd,GAAP;AACH;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,SAASC,WAAT,CAAqBC,UAArB,EAAiCC,aAAjC,EAAgD;AACnD,MAAI,CAACA,aAAL,EAAoB;AAChB;AACH;;AACD,QAAMC,eAAe,GAAGtB,UAAU,CAACiB,OAAX,CAAmBG,UAAnB,CAAxB;;AACA,OAAK,MAAM,CAACG,GAAD,EAAMC,KAAN,CAAX,IAA2BC,MAAM,CAACC,OAAP,CAAeL,aAAf,CAA3B,EAA0D;AACtD,QAAIG,KAAK,IAAI,IAAb,EAAmB;AACfF,MAAAA,eAAe,CAACC,GAAD,CAAf,GAAuBC,KAAvB;AACH;AACJ;;AACD,SAAOF,eAAP;AACH;AACD,OAAO,SAASK,sBAAT,CAAgCH,KAAhC,EAAuC;AAC1C,MAAIvB,QAAQ,CAACuB,KAAD,CAAZ,EAAqB;AACjB,WAAOA,KAAP;AACH,GAFD,MAGK,IAAItB,QAAQ,CAACsB,KAAD,CAAZ,EAAqB;AACtB,WAAOI,MAAM,CAACJ,KAAD,CAAb;AACH,GAFI,MAGA;AACD,UAAM,IAAIK,KAAJ,CAAW,kBAAiBL,KAAM,EAAlC,CAAN;AACH;AACJ","sourcesContent":["import { StyleSheet } from \"react-native\";\nimport { isString, isNumber } from \"lodash\";\nexport function extractStyles(style) {\n const { color, fontFamily, fontWeight, fontSize, lineHeight, letterSpacing, textTransform, textAlign, textDecorationLine, textDecorationColor, textDecorationStyle, ...viewStyles } = StyleSheet.flatten(style || {});\n const textStyles = {\n color,\n fontFamily,\n fontWeight,\n fontSize,\n lineHeight,\n letterSpacing,\n textTransform,\n textAlign,\n textDecorationLine,\n textDecorationColor,\n textDecorationStyle,\n };\n return { viewStyles, textStyles };\n}\n/**\n * Merges a style object on top of another style object. In React Native,\n * keys with undefined values in a style object will still override styles\n * that appear earlier in a sequence. This avoids that problem.\n *\n * This lets us avoid the `...(something ? { something } : {})` pattern.\n * There doesn't seem to be a better way to do this. These all seem to not\n * work (i.e. they all result in `{ color: undefined }`:\n * `const mergedStyles = [{ color: \"red\" }, { color: undefined }]`\n * `const mergedStyles = StyleSheet.compose({ color: \"red\" }, { color: undefined })`\n * `const mergedStyles = StyleSheet.flatten([{ color: \"red\" }, { color: undefined }])`\n */\nexport function applyStyles(baseStyles, stylesToApply) {\n if (!stylesToApply) {\n return;\n }\n const flattenedStyles = StyleSheet.flatten(baseStyles);\n for (const [key, value] of Object.entries(stylesToApply)) {\n if (value != null) {\n flattenedStyles[key] = value;\n }\n }\n return flattenedStyles;\n}\nexport function getValueForRadioButton(value) {\n if (isString(value)) {\n return value;\n }\n else if (isNumber(value)) {\n return String(value);\n }\n else {\n throw new Error(`Invalid value: ${value}`);\n }\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@draftbit/core",
|
|
3
|
-
"version": "43.7.2-
|
|
3
|
+
"version": "43.7.2-5b80c5.1+5b80c5be",
|
|
4
4
|
"description": "Core (non-native) Components",
|
|
5
5
|
"main": "lib/commonjs/index.js",
|
|
6
6
|
"module": "lib/module/index.js",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"@date-io/date-fns": "^1.3.13",
|
|
43
43
|
"@draftbit/react-theme-provider": "^2.1.1",
|
|
44
|
-
"@draftbit/types": "^43.7.2-
|
|
44
|
+
"@draftbit/types": "^43.7.2-5b80c5.1+5b80c5be",
|
|
45
45
|
"@material-ui/core": "^4.11.0",
|
|
46
46
|
"@material-ui/pickers": "^3.2.10",
|
|
47
47
|
"@react-native-community/slider": "4.1.7",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
]
|
|
81
81
|
]
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "5b80c5be0e842262b3641ec00f42adb137d81417"
|
|
84
84
|
}
|