@pingux/astro 2.164.0 → 2.164.1-alpha.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/lib/cjs/components/TimeField/TimeField.styles.js +1 -1
- package/lib/cjs/components/TimeField/TimeSegment.js +2 -1
- package/lib/cjs/components/TimeField/stories/OnyxTimeField.d.ts +2 -0
- package/lib/cjs/components/TimeField/stories/OnyxTimeField.js +39 -0
- package/lib/cjs/components/TimeField/stories/TimeFieldOnyx.chromatic.stories.d.ts +5 -0
- package/lib/cjs/components/TimeField/stories/TimeFieldOnyx.chromatic.stories.js +20 -0
- package/lib/cjs/components/TimeField/stories/TimeFieldOnyxDark.chromatic.stories.d.ts +5 -0
- package/lib/cjs/components/TimeField/stories/TimeFieldOnyxDark.chromatic.stories.js +20 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/forms.d.ts +1 -0
- package/lib/cjs/styles/themeOverrides/nextGenDarkMode/variants/forms.js +1 -0
- package/lib/cjs/styles/themes/next-gen/convertedComponentList.js +1 -1
- package/lib/cjs/styles/themes/next-gen/forms.d.ts +1810 -0
- package/lib/cjs/styles/themes/next-gen/forms.js +36 -2
- package/lib/cjs/styles/themes/next-gen/next-gen.d.ts +905 -0
- package/lib/components/TimeField/TimeField.styles.js +1 -1
- package/lib/components/TimeField/TimeSegment.js +2 -1
- package/lib/components/TimeField/stories/OnyxTimeField.js +31 -0
- package/lib/components/TimeField/stories/TimeFieldOnyx.chromatic.stories.js +12 -0
- package/lib/components/TimeField/stories/TimeFieldOnyxDark.chromatic.stories.js +12 -0
- package/lib/styles/themeOverrides/nextGenDarkMode/variants/forms.js +1 -0
- package/lib/styles/themes/next-gen/convertedComponentList.js +1 -1
- package/lib/styles/themes/next-gen/forms.js +35 -1
- package/lib/tsconfig.lib.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import _extends from "@babel/runtime-corejs3/helpers/esm/extends";
|
|
2
|
+
import _trimInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/trim";
|
|
2
3
|
import React, { useCallback, useRef } from 'react';
|
|
3
4
|
import { useFocusManager } from 'react-aria';
|
|
4
5
|
import { useDateSegment } from '@react-aria/datepicker';
|
|
@@ -43,6 +44,6 @@ var TimeSegment = function TimeSegment(props) {
|
|
|
43
44
|
ref: ref,
|
|
44
45
|
variant: "forms.timeField.segment",
|
|
45
46
|
onKeyUp: handleKeyEvents
|
|
46
|
-
}), text);
|
|
47
|
+
}), _trimInstanceProperty(text).call(text));
|
|
47
48
|
};
|
|
48
49
|
export default TimeSegment;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Box, TimeField } from '../../..';
|
|
3
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
4
|
+
var OnyxTimeField = function OnyxTimeField() {
|
|
5
|
+
return ___EmotionJSX(Box, {
|
|
6
|
+
gap: "md",
|
|
7
|
+
p: "md"
|
|
8
|
+
}, ___EmotionJSX(TimeField, {
|
|
9
|
+
"aria-label": "timeField-default"
|
|
10
|
+
}), ___EmotionJSX(TimeField, {
|
|
11
|
+
"aria-label": "timeField-default",
|
|
12
|
+
defaultValue: "12:30",
|
|
13
|
+
hourCycle: 12,
|
|
14
|
+
granularity: "second"
|
|
15
|
+
}), ___EmotionJSX(TimeField, {
|
|
16
|
+
"aria-label": "timeField-default",
|
|
17
|
+
isDisabled: true
|
|
18
|
+
}), ___EmotionJSX(TimeField, {
|
|
19
|
+
"aria-label": "timeField-default",
|
|
20
|
+
isReadOnly: true
|
|
21
|
+
}), ___EmotionJSX(TimeField, {
|
|
22
|
+
"aria-label": "timeField-default",
|
|
23
|
+
isRequired: true,
|
|
24
|
+
label: "Lorem Ipsum"
|
|
25
|
+
}), ___EmotionJSX(TimeField, {
|
|
26
|
+
"aria-label": "timeField-default",
|
|
27
|
+
defaultValue: "12:30",
|
|
28
|
+
isInvalid: true
|
|
29
|
+
}));
|
|
30
|
+
};
|
|
31
|
+
export default OnyxTimeField;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { AstroProvider, OnyxTheme } from '../../..';
|
|
3
|
+
import OnyxTimeField from './OnyxTimeField';
|
|
4
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
5
|
+
export default {
|
|
6
|
+
title: 'Onyx TimeField'
|
|
7
|
+
};
|
|
8
|
+
export var Default = function Default() {
|
|
9
|
+
return ___EmotionJSX(AstroProvider, {
|
|
10
|
+
theme: OnyxTheme
|
|
11
|
+
}, ___EmotionJSX(OnyxTimeField, null));
|
|
12
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { AstroProvider, OnyxDarkTheme } from '../../..';
|
|
3
|
+
import OnyxTimeField from './OnyxTimeField';
|
|
4
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
5
|
+
export default {
|
|
6
|
+
title: 'Onyx Dark TimeField'
|
|
7
|
+
};
|
|
8
|
+
export var Default = function Default() {
|
|
9
|
+
return ___EmotionJSX(AstroProvider, {
|
|
10
|
+
theme: OnyxDarkTheme
|
|
11
|
+
}, ___EmotionJSX(OnyxTimeField, null));
|
|
12
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var nextGenConvertedComponents = ['AccordionGridGroup', 'AccordionGroup', 'ArrayField', 'AstroProvider', 'Avatar', 'Badge', 'Base Components', 'Breadcrumbs', 'Button', 'ButtonBar', 'Callout', 'Card', 'CheckboxField', 'CodeView', 'ColorField', 'ComboBoxField', 'CopyText', 'DataTable', 'EnvironmentBreadcrumb', 'GridList', 'HelpHint', 'Icon', 'IconBadge', 'IconButton', 'IconWrapper', 'ImageUploadField', 'Loader', 'Link', 'LinkSelectField', 'ListView', 'ListViewItem', 'Message', 'Messages', 'Modal', 'MultiValuesField', 'MultivaluesField', 'NavBar', 'NavigationHeader', 'NextGen ListViewItem', 'NumberField', 'OverlayPanel', 'PageHeader', 'Pagination', 'PanelHeader', 'PasswordField', 'PopoverMenu', 'ProgressBar', 'RadioField', 'RadioGroupField', 'RangeCalendar', 'RequirementsList', 'RockerButtonGroup', 'SearchField', 'SearchNav', 'SelectField', 'Skeleton', 'SliderField', 'Stepper', 'Sticker Sheet', 'SwitchField', 'StatusIcon', 'Table', 'TableBase', 'Tabs', 'Text', 'TextAreaField', 'TextField', 'TooltipTrigger', 'ArrayField', 'ColorField', 'LinkSelectField', 'NumberField', 'SwitchField', 'Base Components', 'SliderField', 'ServerErrorBoundary', 'Avatar', 'Box'];
|
|
1
|
+
var nextGenConvertedComponents = ['AccordionGridGroup', 'AccordionGroup', 'ArrayField', 'AstroProvider', 'Avatar', 'Badge', 'Base Components', 'Breadcrumbs', 'Button', 'ButtonBar', 'Callout', 'Card', 'CheckboxField', 'CodeView', 'ColorField', 'ComboBoxField', 'CopyText', 'DataTable', 'EnvironmentBreadcrumb', 'GridList', 'HelpHint', 'Icon', 'IconBadge', 'IconButton', 'IconWrapper', 'ImageUploadField', 'Loader', 'Link', 'LinkSelectField', 'ListView', 'ListViewItem', 'Message', 'Messages', 'Modal', 'MultiValuesField', 'MultivaluesField', 'NavBar', 'NavigationHeader', 'NextGen ListViewItem', 'NumberField', 'OverlayPanel', 'PageHeader', 'Pagination', 'PanelHeader', 'PasswordField', 'PopoverMenu', 'ProgressBar', 'RadioField', 'RadioGroupField', 'RangeCalendar', 'RequirementsList', 'RockerButtonGroup', 'SearchField', 'SearchNav', 'SelectField', 'Skeleton', 'SliderField', 'Stepper', 'Sticker Sheet', 'SwitchField', 'StatusIcon', 'Table', 'TableBase', 'Tabs', 'Text', 'TextAreaField', 'TextField', 'TooltipTrigger', 'ArrayField', 'ColorField', 'LinkSelectField', 'NumberField', 'SwitchField', 'Base Components', 'SliderField', 'ServerErrorBoundary', 'Avatar', 'Box', 'TimeField'];
|
|
2
2
|
export var componentSpecificNextGenBlacklist = {
|
|
3
3
|
AstroProvider: ['Default', 'With Custom Theme Override'],
|
|
4
4
|
Messages: ['Customization'],
|
|
@@ -92,6 +92,39 @@ export var radio = {
|
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
};
|
|
95
|
+
export var timeField = {
|
|
96
|
+
inputField: _objectSpread(_objectSpread({}, input), {}, {
|
|
97
|
+
color: 'font.base',
|
|
98
|
+
alignItems: 'center',
|
|
99
|
+
justifyContent: 'center',
|
|
100
|
+
lineHeight: 'body',
|
|
101
|
+
minWidth: '105px',
|
|
102
|
+
'&:focus-within:not(.is-read-only)': {
|
|
103
|
+
borderColor: 'focus',
|
|
104
|
+
outline: '1px solid',
|
|
105
|
+
outlineColor: 'focus',
|
|
106
|
+
outlineOffset: '0px'
|
|
107
|
+
},
|
|
108
|
+
'&.is-read-only': {
|
|
109
|
+
border: '1px solid',
|
|
110
|
+
borderColor: 'border.input',
|
|
111
|
+
backgroundColor: 'disabled'
|
|
112
|
+
},
|
|
113
|
+
'&.is-disabled': {
|
|
114
|
+
opacity: 1,
|
|
115
|
+
border: '1px solid',
|
|
116
|
+
borderColor: 'border.input',
|
|
117
|
+
backgroundColor: 'disabled'
|
|
118
|
+
}
|
|
119
|
+
}),
|
|
120
|
+
segment: {
|
|
121
|
+
px: '2px',
|
|
122
|
+
textTransform: 'uppercase',
|
|
123
|
+
'&:empty': {
|
|
124
|
+
px: 0
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
};
|
|
95
128
|
export default {
|
|
96
129
|
input: input,
|
|
97
130
|
label: label,
|
|
@@ -101,5 +134,6 @@ export default {
|
|
|
101
134
|
radio: radio,
|
|
102
135
|
search: search,
|
|
103
136
|
"switch": switchable,
|
|
104
|
-
numberField: numberField
|
|
137
|
+
numberField: numberField,
|
|
138
|
+
timeField: timeField
|
|
105
139
|
};
|