@lingxiteam/theme-utils 0.1.14 → 0.1.15

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,4 +1,5 @@
1
1
  export declare const MOBILE_ASSETS_CSS_TPL: any;
2
+ export declare const mobileExtend: any;
2
3
  export declare const MOBILE_ASSETS_COMPONENT_LIST: unknown[];
3
4
  export declare function getMobileItemByType(type: string): any;
4
5
  export declare function px2rem(obj: any): any;
package/dist/lx-mobile.js CHANGED
@@ -64,7 +64,7 @@ export var MOBILE_ASSETS_CSS_TPL = {
64
64
  DformFile: DformFile,
65
65
  Accordion: Accordion
66
66
  };
67
- var extend = {
67
+ export var mobileExtend = {
68
68
  DformInput: 'DForm',
69
69
  DformTextArea: 'DForm',
70
70
  DformInputNumber: 'DForm',
@@ -131,8 +131,8 @@ export function parseValueRem(values) {
131
131
 
132
132
  // 临时解决方案,将只对它有影响的值,生成继承的样式
133
133
  export function stringifyMobileCssByTypePreview(type, values) {
134
- if (extend[type]) {
135
- var cfg = getMobileItemByType(extend[type]);
134
+ if (mobileExtend[type]) {
135
+ var cfg = getMobileItemByType(mobileExtend[type]);
136
136
  var _item = getMobileItemByType(type);
137
137
  return stringifyCss(cfg.tpl, px2rem(_objectSpread(_objectSpread({}, cfg.defaultValue[0]), values))) + stringifyCss(_item.tpl, px2rem(values));
138
138
  }
@@ -148,9 +148,9 @@ export function parseMobileCssByType(type, css) {
148
148
  return parseValueRem(parseCss(item.tpl, css));
149
149
  }
150
150
  export function prefixMobileCSS(type, values, prefix) {
151
- if (extend[type]) {
151
+ if (mobileExtend[type]) {
152
152
  var _cfg$itemCustomTpl;
153
- var cfg = getMobileItemByType(extend[type]);
153
+ var cfg = getMobileItemByType(mobileExtend[type]);
154
154
  var _item2 = getMobileItemByType(type);
155
155
  return prefixAnyCSS(stringifyCss((_cfg$itemCustomTpl = cfg === null || cfg === void 0 ? void 0 : cfg.itemCustomTpl) !== null && _cfg$itemCustomTpl !== void 0 ? _cfg$itemCustomTpl : cfg === null || cfg === void 0 ? void 0 : cfg.tpl, px2rem(_objectSpread(_objectSpread({}, cfg.defaultValue[0]), values))), prefix, cfg === null || cfg === void 0 ? void 0 : cfg.hasPrefixClass) + prefixAnyCSS(stringifyCss(_item2.tpl, px2rem(values)), prefix, _item2 === null || _item2 === void 0 ? void 0 : _item2.hasPrefixClass);
156
156
  }
package/dist/lx.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export declare const ASSETS_CSS_TPL: any;
2
+ export declare const pcExtend: any;
2
3
  export declare const ASSETS_COMPONENT_LIST: unknown[];
3
4
  export declare function getItemByType(type: string): any;
4
5
  export declare function stringifyCssByType(type: string, values: any): string;
package/dist/lx.js CHANGED
@@ -64,7 +64,7 @@ export var ASSETS_CSS_TPL = {
64
64
  Tree: Tree,
65
65
  Description: Description
66
66
  };
67
- var extend = {
67
+ export var pcExtend = {
68
68
  Input: 'Form',
69
69
  TextArea: 'Form',
70
70
  InputNumber: 'Form',
@@ -97,8 +97,8 @@ export function stringifyCssByType(type, values) {
97
97
 
98
98
  // 临时解决方案,将只对它有影响的值,生成继承的样式
99
99
  export function stringifyCssByTypePreview(type, values) {
100
- if (extend[type]) {
101
- var cfg = getItemByType(extend[type]);
100
+ if (pcExtend[type]) {
101
+ var cfg = getItemByType(pcExtend[type]);
102
102
  var _item = getItemByType(type);
103
103
  return stringifyCss(cfg.tpl, _objectSpread(_objectSpread({}, cfg.defaultValue[0]), values)) + stringifyCss(_item.tpl, values);
104
104
  }
@@ -110,9 +110,9 @@ export function parseCssByType(type, css) {
110
110
  return parseCss(item.tpl, css);
111
111
  }
112
112
  export function prefixCSS(type, values, prefix) {
113
- if (extend[type]) {
113
+ if (pcExtend[type]) {
114
114
  var _cfg$itemCustomTpl;
115
- var cfg = getItemByType(extend[type]);
115
+ var cfg = getItemByType(pcExtend[type]);
116
116
  var _item2 = getItemByType(type);
117
117
  return prefixAnyCSS(stringifyCss((_cfg$itemCustomTpl = cfg === null || cfg === void 0 ? void 0 : cfg.itemCustomTpl) !== null && _cfg$itemCustomTpl !== void 0 ? _cfg$itemCustomTpl : cfg === null || cfg === void 0 ? void 0 : cfg.tpl, _objectSpread(_objectSpread({}, cfg.defaultValue[0]), values)), prefix, cfg === null || cfg === void 0 ? void 0 : cfg.hasPrefixClass) + prefixAnyCSS(stringifyCss(_item2.tpl, values), prefix, _item2 === null || _item2 === void 0 ? void 0 : _item2.hasPrefixClass);
118
118
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lingxiteam/theme-utils",
3
- "version": "0.1.14",
3
+ "version": "0.1.15",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",