@antscorp/antsomi-ui 1.3.5-beta.676 → 1.3.5-beta.678

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.
@@ -64,6 +64,8 @@ export const AdvancedPicker = props => {
64
64
  },
65
65
  date: dayjs().tz(timezone).format(format),
66
66
  dateDisplay: dayjs().tz(timezone).format(format),
67
+ // date: dayjs(propsDate).tz(timezone).format(format),
68
+ // dateDisplay: dayjs(propsDate).tz(timezone).format(format),
67
69
  });
68
70
  const { isOpen, option, date, dateDisplay } = state;
69
71
  const isShowFixed = option.dateType.value === 'fixed' || onlyShowFixed;
@@ -146,9 +148,17 @@ export const AdvancedPicker = props => {
146
148
  }
147
149
  }, [option, format, timezone]);
148
150
  useDeepCompareEffect(() => {
151
+ const DEFAULT_OPTION = onlyShowFixed
152
+ ? {
153
+ dateType: 'fixed',
154
+ calculationDate: 'days',
155
+ calculationType: 'minus',
156
+ value: 0,
157
+ }
158
+ : {};
149
159
  try {
150
- if (propsOption) {
151
- const { dateType, calculationType, calculationDate, value = 0 } = propsOption || {};
160
+ if (propsOption || onlyShowFixed) {
161
+ const { dateType, calculationType, calculationDate, value = 0, } = propsOption || DEFAULT_OPTION;
152
162
  const newDateTypes = DATE_TYPES;
153
163
  const newDateType = newDateTypes.find(dType => dType.value === dateType);
154
164
  const newCalculationType = CALCULATION_TYPES.find(calType => calType.value === calculationType);
@@ -345,7 +345,7 @@ export const UploadImage = props => {
345
345
  React.createElement(Input, { label: mode === 'video' ? 'Video URL' : 'Image URL', required: required, placeholder: placeholder, value: selectedMedia.url ? selectedMedia.url : '', focused: focused, onAfterChange: value => handleSelectMedia({
346
346
  url: value,
347
347
  }) }))))),
348
- React.createElement(Modal, { title: labelModalDelete, visible: isOpenConfirmDelete, onOk: () => handleRemoveUploadedMedia(deleteMediaRef.current, false), onCancel: () => setOpenConfirmDelete(prev => !prev), okText: "OK", cancelText: "Cancel", destroyOnClose: true },
348
+ React.createElement(Modal, { title: labelModalDelete, open: isOpenConfirmDelete, onOk: () => handleRemoveUploadedMedia(deleteMediaRef.current, false), onCancel: () => setOpenConfirmDelete(prev => !prev), okText: "OK", cancelText: "Cancel", destroyOnClose: true },
349
349
  React.createElement("p", null,
350
350
  "Are you sure you want to delete ", (_d = deleteMediaRef.current) === null || _d === void 0 ? void 0 :
351
351
  _d.name,
@@ -50,18 +50,26 @@ export const GlobalStyle = () => {
50
50
 
51
51
  /* width */
52
52
  ::-webkit-scrollbar {
53
+ background: transparent !important;
53
54
  width: ${scrollBarSize} !important;
54
55
  height: ${scrollBarSize} !important;
55
56
  }
56
57
 
57
58
  /* Track */
58
59
  ::-webkit-scrollbar-track {
59
- background: #fff !important;
60
+ background: transparent !important;
60
61
  }
61
62
 
62
63
  /* Handle */
63
64
  ::-webkit-scrollbar-thumb {
64
- background: ${gray5};
65
+ background-color: transparent;
66
+ border-radius: 4px;
67
+ }
68
+
69
+ *:hover {
70
+ &::-webkit-scrollbar-thumb {
71
+ background-color: ${gray5} !important;
72
+ }
65
73
  }
66
74
 
67
75
  .rc-virtual-list {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@antscorp/antsomi-ui",
3
- "version": "1.3.5-beta.676",
3
+ "version": "1.3.5-beta.678",
4
4
  "description": "An enterprise-class UI design language and React UI library.",
5
5
  "sideEffects": [
6
6
  "dist/*",