@pisell/materials 2.2.37 → 2.2.39

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.
@@ -5,11 +5,11 @@
5
5
  display: flex;
6
6
  align-items: center;
7
7
  gap: 8px;
8
- padding-right: 24px;
8
+ padding-right: 0 !important;
9
9
  }
10
10
 
11
11
  &-product-options-header {
12
- align-items: initial;
12
+ align-items: normal;
13
13
  }
14
14
 
15
15
  &-product-delete {
@@ -45,6 +45,7 @@
45
45
  line-height: 24px;
46
46
  display: flex;
47
47
  flex-direction: column;
48
+ padding-right: 24px;
48
49
  }
49
50
 
50
51
  &-product-title-price {
@@ -1,4 +1,7 @@
1
1
  import dayjs from 'dayjs';
2
+ import 'dayjs/locale/zh-cn';
3
+ import 'dayjs/locale/en';
4
+ import 'dayjs/locale/zh-tw';
2
5
  declare type RType = (url: string, data?: {} | undefined, config?: {} | undefined) => Promise<any>;
3
6
  declare class Request {
4
7
  private request;
@@ -16,6 +16,9 @@ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input ==
16
16
  import dayjs from 'dayjs';
17
17
  import { locales } from '@pisell/utils';
18
18
  import { intersectionBy } from 'lodash';
19
+ import 'dayjs/locale/zh-cn';
20
+ import 'dayjs/locale/en';
21
+ import 'dayjs/locale/zh-tw';
19
22
  var Request = /*#__PURE__*/function () {
20
23
  function Request() {
21
24
  _classCallCheck(this, Request);
@@ -149,7 +152,13 @@ export var getServiceTime = function getServiceTime(item, currentDate) {
149
152
  if (!currentDate || !(item !== null && item !== void 0 && (_item$_extend = item._extend) !== null && _item$_extend !== void 0 && _item$_extend.start_time) || !dayjs(currentDate).isValid()) return '';
150
153
  var locale = (item === null || item === void 0 ? void 0 : item.locale) || 'en-US';
151
154
  var isEn = locale === 'en-US' || locale === 'en';
152
- dayjs.locale(locale);
155
+ var localeTypes = {
156
+ 'en-US': 'en',
157
+ 'zh-CN': 'zh-cn',
158
+ 'zh-HK': 'zh-tw'
159
+ };
160
+ dayjs.locale(localeTypes[locale]);
161
+ console.log(locale, 'wh_locale');
153
162
  var startDate = dayjs((currentDate === null || currentDate === void 0 ? void 0 : currentDate.format('YYYY-MM-DD')) + ' ' + getServeStartTime(item === null || item === void 0 ? void 0 : (_item$_extend2 = item._extend) === null || _item$_extend2 === void 0 ? void 0 : _item$_extend2.start_time));
154
163
  var startTime = startDate.format('HH:mm');
155
164
 
@@ -155,7 +155,7 @@ export declare const getSettingKeyArrByMode: ({ filter, columnSetting, dataSourc
155
155
  sort?: SortType | undefined;
156
156
  mode: "" | "localStorage" | "remote";
157
157
  currentViewMode: ModeType;
158
- }) => ("filter_setting" | "column_setting" | "gallery_setting" | "view_mode" | "group_by" | "order_by")[];
158
+ }) => ("view_mode" | "column_setting" | "order_by" | "group_by" | "gallery_setting" | "filter_setting")[];
159
159
  export declare const omit: (obj: Record<string, any>, keys: string[]) => Record<string, any>;
160
160
  export declare const stringify: (obj: Record<string, any>) => string;
161
161
  export {};
@@ -5,11 +5,11 @@
5
5
  display: flex;
6
6
  align-items: center;
7
7
  gap: 8px;
8
- padding-right: 24px;
8
+ padding-right: 0 !important;
9
9
  }
10
10
 
11
11
  &-product-options-header {
12
- align-items: initial;
12
+ align-items: normal;
13
13
  }
14
14
 
15
15
  &-product-delete {
@@ -45,6 +45,7 @@
45
45
  line-height: 24px;
46
46
  display: flex;
47
47
  flex-direction: column;
48
+ padding-right: 24px;
48
49
  }
49
50
 
50
51
  &-product-title-price {
@@ -1,4 +1,7 @@
1
1
  import dayjs from 'dayjs';
2
+ import 'dayjs/locale/zh-cn';
3
+ import 'dayjs/locale/en';
4
+ import 'dayjs/locale/zh-tw';
2
5
  declare type RType = (url: string, data?: {} | undefined, config?: {} | undefined) => Promise<any>;
3
6
  declare class Request {
4
7
  private request;
@@ -60,6 +60,9 @@ module.exports = __toCommonJS(utils_exports);
60
60
  var import_dayjs = __toESM(require("dayjs"));
61
61
  var import_utils = require("@pisell/utils");
62
62
  var import_lodash = require("lodash");
63
+ var import_zh_cn = require("dayjs/locale/zh-cn");
64
+ var import_en = require("dayjs/locale/en");
65
+ var import_zh_tw = require("dayjs/locale/zh-tw");
63
66
  var Request = class {
64
67
  constructor() {
65
68
  this.request = {};
@@ -142,7 +145,13 @@ var getServiceTime = (item, currentDate) => {
142
145
  return "";
143
146
  const locale = (item == null ? void 0 : item.locale) || "en-US";
144
147
  const isEn = locale === "en-US" || locale === "en";
145
- import_dayjs.default.locale(locale);
148
+ const localeTypes = {
149
+ "en-US": "en",
150
+ "zh-CN": "zh-cn",
151
+ "zh-HK": "zh-tw"
152
+ };
153
+ import_dayjs.default.locale(localeTypes[locale]);
154
+ console.log(locale, "wh_locale");
146
155
  const startDate = (0, import_dayjs.default)(
147
156
  (currentDate == null ? void 0 : currentDate.format("YYYY-MM-DD")) + " " + getServeStartTime((_b = item == null ? void 0 : item._extend) == null ? void 0 : _b.start_time)
148
157
  );
@@ -155,7 +155,7 @@ export declare const getSettingKeyArrByMode: ({ filter, columnSetting, dataSourc
155
155
  sort?: SortType | undefined;
156
156
  mode: "" | "localStorage" | "remote";
157
157
  currentViewMode: ModeType;
158
- }) => ("filter_setting" | "column_setting" | "gallery_setting" | "view_mode" | "group_by" | "order_by")[];
158
+ }) => ("view_mode" | "column_setting" | "order_by" | "group_by" | "gallery_setting" | "filter_setting")[];
159
159
  export declare const omit: (obj: Record<string, any>, keys: string[]) => Record<string, any>;
160
160
  export declare const stringify: (obj: Record<string, any>) => string;
161
161
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/materials",
3
- "version": "2.2.37",
3
+ "version": "2.2.39",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",