ikualo-ui-kit-mobile 1.2.6 → 1.2.9

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ikualo-ui-kit-mobile",
3
- "version": "1.2.6",
3
+ "version": "1.2.9",
4
4
  "main": "src/index.ts",
5
5
  "scripts": {
6
6
  "start": "expo start",
@@ -178,7 +178,7 @@ const dark = {
178
178
  text_high_secondary: colors.secondary_300,
179
179
  text_disabled: colors.gray_500,
180
180
 
181
- text_btn: colors.gray_800,
181
+ text_btn: colors.base_dark,
182
182
  text_btn_alt: colors.secondary_alte,
183
183
  text_btn_disabled: colors.gray_500,
184
184
  text_home: colors.gray_200,
@@ -32,6 +32,7 @@ export const BtnContained = (props: IBtnContained) => {
32
32
  labelStyle={[
33
33
  stylesButtonContained['btn-contained-text'],
34
34
  stylesButtonContained[`btn-contained--${size ?? 'md'}`],
35
+ { color: stylesButtonContained[`btn-contained--${color ?? 'primary'}`].color },
35
36
  isDisabled && stylesButtonContained[`btn-contained--disabled`],
36
37
  labelStyle ?? '',
37
38
  ]}
@@ -1,10 +1,10 @@
1
1
  import { HelperText, TextInput, Text } from 'react-native-paper';
2
2
  import { getStyleInput } from '../../../assets/styles/elements/inputs';
3
3
  import { useState } from 'react';
4
- import { View } from 'react-native';
4
+ import { Platform, View } from 'react-native';
5
5
  import React from 'react';
6
6
  import useStore from '../../store';
7
- import { IInputDate, IInputText } from '../../models';
7
+ import { IInputDate } from '../../models';
8
8
  import { ErrorInputIcon } from '../../../assets/icons/svgs';
9
9
  import { MaterialCommunityIcons } from '@expo/vector-icons';
10
10
  import RNDateTimePicker from '@react-native-community/datetimepicker';
@@ -153,33 +153,48 @@ export const InputDateTime = (props: IInputDate) => {
153
153
  )}
154
154
  </>
155
155
  )}
156
- <DialogDown
157
- isVisible={showDialogDate}
158
- title={label ?? ''}
159
- onDismiss={() => {
160
- setDialogDate(false);
161
- if (!value && required) {
162
- setErrorRequired(true);
163
- onInvalid && onInvalid();
164
- }
165
- }}
166
- >
167
- <RNDateTimePicker
168
- display="spinner"
169
- mode={type}
170
- locale={lang}
171
- value={value || new Date()}
172
- onChange={(event, date) => {
173
- if (date) onChangeText(date);
174
- }}
175
- />
176
- <BtnContained
177
- text={textBtnSave}
178
- onPress={() => {
156
+ {Platform.OS === 'ios' ? (
157
+ <DialogDown
158
+ isVisible={showDialogDate}
159
+ title={label ?? ''}
160
+ onDismiss={() => {
179
161
  setDialogDate(false);
162
+ if (!value && required) {
163
+ setErrorRequired(true);
164
+ onInvalid && onInvalid();
165
+ }
180
166
  }}
181
- />
182
- </DialogDown>
167
+ >
168
+ <RNDateTimePicker
169
+ display="spinner"
170
+ mode={type}
171
+ locale={lang}
172
+ value={value || new Date()}
173
+ onChange={(event, date) => {
174
+ if (date) onChangeText(date);
175
+ }}
176
+ />
177
+ <BtnContained
178
+ text={textBtnSave}
179
+ onPress={() => {
180
+ setDialogDate(false);
181
+ }}
182
+ />
183
+ </DialogDown>
184
+ ) : (
185
+ showDialogDate && (
186
+ <RNDateTimePicker
187
+ display="spinner"
188
+ mode={type}
189
+ locale={lang}
190
+ value={value || new Date()}
191
+ onChange={(event, date) => {
192
+ if (date) onChangeText(date);
193
+ setDialogDate(false);
194
+ }}
195
+ />
196
+ )
197
+ )}
183
198
  </View>
184
199
  );
185
200
  };