decathlon-ui 0.3.2 → 0.3.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.
@@ -1 +1 @@
1
- {"version":3,"file":"information-card.component.d.ts","sourceRoot":"","sources":["../../../src/components/information-card/information-card.component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAgFrE,eAAO,MAAM,eAAe,kDAAuC,CAAC"}
1
+ {"version":3,"file":"information-card.component.d.ts","sourceRoot":"","sources":["../../../src/components/information-card/information-card.component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAmFrE,eAAO,MAAM,eAAe,kDAAuC,CAAC"}
@@ -39,7 +39,7 @@ const processHighlightedText = (text, normalStyle, highlightedStyle) => {
39
39
  };
40
40
  const InformationCardComponent = ({ title, description, style, titleStyle, descriptionStyle, highlightedTextStyle, ...rest }) => {
41
41
  const styles = useInformationCardStyles();
42
- return (_jsxs(View, { style: [styles.container, style], ...rest, children: [_jsx(View, { style: { flexDirection: 'row', flexWrap: 'wrap' }, children: processHighlightedText(title, [styles.title, titleStyle], [styles.highlightedText, highlightedTextStyle]) }), _jsx(View, { style: { flexDirection: 'row', flexWrap: 'wrap' }, children: processHighlightedText(description, [styles.description, descriptionStyle], [styles.highlightedText, highlightedTextStyle]) })] }));
42
+ return (_jsxs(View, { style: [styles.container, style], ...rest, children: [title && (_jsx(View, { style: { flexDirection: 'row', flexWrap: 'wrap' }, children: processHighlightedText(title, [styles.title, titleStyle], [styles.highlightedText, highlightedTextStyle]) })), _jsx(View, { style: { flexDirection: 'row', flexWrap: 'wrap' }, children: processHighlightedText(description, [styles.description, descriptionStyle], [styles.highlightedText, highlightedTextStyle]) })] }));
43
43
  };
44
44
  export const InformationCard = React.memo(InformationCardComponent);
45
45
  InformationCard.displayName = "InformationCard";
@@ -5,7 +5,7 @@ export interface InformationCardProps {
5
5
  * Use %s para indicar partes a serem destacadas
6
6
  * Ex: "Vales e %scartão presente%s:"
7
7
  */
8
- title: string;
8
+ title?: string;
9
9
  /**
10
10
  * Descrição/subtítulo do card
11
11
  * Use %s para indicar partes a serem destacadas
@@ -1 +1 @@
1
- {"version":3,"file":"information-card.types.d.ts","sourceRoot":"","sources":["../../../src/components/information-card/information-card.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEpD,MAAM,WAAW,oBAAoB;IACnC;;;;OAIG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;;;OAIG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB;;OAEG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC;IAEvB;;OAEG;IACH,gBAAgB,CAAC,EAAE,SAAS,CAAC;IAE7B;;OAEG;IACH,oBAAoB,CAAC,EAAE,SAAS,CAAC;CAClC"}
1
+ {"version":3,"file":"information-card.types.d.ts","sourceRoot":"","sources":["../../../src/components/information-card/information-card.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEpD,MAAM,WAAW,oBAAoB;IACnC;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;;OAIG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB;;OAEG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC;IAEvB;;OAEG;IACH,gBAAgB,CAAC,EAAE,SAAS,CAAC;IAE7B;;OAEG;IACH,oBAAoB,CAAC,EAAE,SAAS,CAAC;CAClC"}
@@ -1 +1 @@
1
- {"version":3,"file":"input.component.d.ts","sourceRoot":"","sources":["../../../src/components/input/input.component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAA6B,cAAc,EAAQ,MAAM,cAAc,CAAC;AAK/E,KAAK,QAAQ,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,CAAC;AAE5D,UAAU,UAAW,SAAQ,cAAc;IACzC,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AA0KD,eAAO,MAAM,KAAK,wCAA6B,CAAC"}
1
+ {"version":3,"file":"input.component.d.ts","sourceRoot":"","sources":["../../../src/components/input/input.component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAA6B,cAAc,EAAQ,MAAM,cAAc,CAAC;AAK/E,KAAK,QAAQ,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,CAAC;AAE5D,UAAU,UAAW,SAAQ,cAAc;IACzC,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AA2KD,eAAO,MAAM,KAAK,wCAA6B,CAAC"}
@@ -87,18 +87,18 @@ const InputComponent = ({ label, placeholder, error, value, disabled = false, ma
87
87
  inputRange: [0, 1],
88
88
  outputRange: [1, 2],
89
89
  });
90
- return (_jsxs(View, { style: styles.container, accessible: true, testID: testID, accessibilityLabel: `${label} input field`, children: [_jsx(View, { style: styles.labelWrapper, children: _jsx(Text, { style: [
90
+ return (_jsxs(View, { style: styles.container, accessible: true, testID: testID, accessibilityLabel: `${label} input field`, children: [label && (_jsx(View, { style: styles.labelWrapper, children: _jsx(Text, { style: [
91
91
  styles.labelText,
92
92
  disabled && styles.disabledText,
93
- ], accessibilityRole: "text", children: label }) }), _jsxs(Animated.View, { style: [
93
+ ], accessibilityRole: "text", children: label }) })), _jsx(Animated.View, { style: [
94
94
  styles.inputContainer,
95
95
  error && styles.inputError,
96
96
  disabled && styles.inputDisabled,
97
97
  isFocused && styles.inputFocused,
98
98
  { borderWidth },
99
- ], children: [_jsx(TextInput, { style: [styles.input, disabled && styles.inputTextDisabled], placeholder: placeholder, value: value, onChangeText: handleChangeText, editable: !disabled, onFocus: () => setIsFocused(true), onBlur: () => setIsFocused(false), accessibilityLabel: label, accessibilityState: {
100
- disabled: disabled,
101
- }, placeholderTextColor: "#A4ADB7", ...rest }), isFocused && _jsx(View, { style: styles.cursor })] }), error && _jsx(ErrorMessage, { message: error })] }));
99
+ ], children: _jsx(TextInput, { style: [styles.input, disabled && styles.inputTextDisabled], placeholder: placeholder, value: value, onChangeText: handleChangeText, editable: !disabled, onFocus: () => setIsFocused(true), onBlur: () => setIsFocused(false), accessibilityLabel: label, accessibilityState: {
100
+ disabled: disabled,
101
+ }, placeholderTextColor: "#A4ADB7", ...rest }) }), error && _jsx(ErrorMessage, { message: error })] }));
102
102
  };
103
103
  export const Input = React.memo(InputComponent);
104
104
  Input.displayName = "Input";
@@ -1,6 +1,6 @@
1
1
  export type MaskType = "cpf" | "phone" | "date" | "cep" | "custom";
2
2
  export interface InputProps {
3
- label: string;
3
+ label?: string;
4
4
  placeholder?: string;
5
5
  error?: string;
6
6
  value?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"input.types.d.ts","sourceRoot":"","sources":["../../../src/components/input/input.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,QAAQ,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,CAAC;AAEnE,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB"}
1
+ {"version":3,"file":"input.types.d.ts","sourceRoot":"","sources":["../../../src/components/input/input.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,QAAQ,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,CAAC;AAEnE,MAAM,WAAW,UAAU;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "decathlon-ui",
3
- "version": "0.3.2",
3
+ "version": "0.3.3",
4
4
  "description": "Biblioteca de componentes React Native com Storybook e documentação via GitHub Pages.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",