cgn-vant 1.0.7 → 1.0.8

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,7 +1,7 @@
1
1
  "use strict";
2
2
  var __webpack_require__ = {};
3
3
  (()=>{
4
- __webpack_require__.d = function(exports1, definition) {
4
+ __webpack_require__.d = (exports1, definition)=>{
5
5
  for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
6
6
  enumerable: true,
7
7
  get: definition[key]
@@ -9,12 +9,10 @@ var __webpack_require__ = {};
9
9
  };
10
10
  })();
11
11
  (()=>{
12
- __webpack_require__.o = function(obj, prop) {
13
- return Object.prototype.hasOwnProperty.call(obj, prop);
14
- };
12
+ __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
15
13
  })();
16
14
  (()=>{
17
- __webpack_require__.r = function(exports1) {
15
+ __webpack_require__.r = (exports1)=>{
18
16
  if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
19
17
  value: 'Module'
20
18
  });
@@ -26,8 +24,8 @@ var __webpack_require__ = {};
26
24
  var __webpack_exports__ = {};
27
25
  __webpack_require__.r(__webpack_exports__);
28
26
  __webpack_require__.d(__webpack_exports__, {
29
- CgnImports: ()=>CgnImports,
30
- CgnResolver: ()=>CgnResolver
27
+ VantImports: ()=>VantImports,
28
+ VantResolver: ()=>VantResolver
31
29
  });
32
30
  function kebabCase(key) {
33
31
  const result = key.replace(/([A-Z])/g, ' $1').trim();
@@ -82,23 +80,21 @@ function getAPIMap() {
82
80
  });
83
81
  return apiMap;
84
82
  }
85
- function CgnResolver(options = {}) {
83
+ function VantResolver(options = {}) {
86
84
  const moduleType = getModuleType(options);
87
85
  const apiMap = getAPIMap();
88
86
  return {
89
87
  type: 'component',
90
88
  resolve: (name)=>{
91
- var _options_exclude;
92
89
  if (name.startsWith('Cgn')) {
93
- var _options_exclude1;
94
90
  const partialName = name.slice(3);
95
- if (!(null === (_options_exclude1 = options.exclude) || void 0 === _options_exclude1 ? void 0 : _options_exclude1.includes(partialName))) return {
91
+ if (!options.exclude?.includes(partialName)) return {
96
92
  name: partialName,
97
93
  from: `cgn-vant/${moduleType}`,
98
94
  sideEffects: getSideEffects(kebabCase(partialName), options)
99
95
  };
100
96
  }
101
- if (apiMap.has(name) && !(null === (_options_exclude = options.exclude) || void 0 === _options_exclude ? void 0 : _options_exclude.includes(name))) {
97
+ if (apiMap.has(name) && !options.exclude?.includes(name)) {
102
98
  const partialName = apiMap.get(name);
103
99
  return {
104
100
  name,
@@ -109,7 +105,7 @@ function CgnResolver(options = {}) {
109
105
  }
110
106
  };
111
107
  }
112
- function CgnImports(options = {}) {
108
+ function VantImports(options = {}) {
113
109
  const moduleType = getModuleType(options);
114
110
  return {
115
111
  [`cgn-vant/${moduleType}`]: [
@@ -117,8 +113,12 @@ function CgnImports(options = {}) {
117
113
  ]
118
114
  };
119
115
  }
120
- var __webpack_export_target__ = exports;
121
- for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
122
- if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
116
+ exports.VantImports = __webpack_exports__.VantImports;
117
+ exports.VantResolver = __webpack_exports__.VantResolver;
118
+ for(var __rspack_i in __webpack_exports__)if (-1 === [
119
+ "VantImports",
120
+ "VantResolver"
121
+ ].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
122
+ Object.defineProperty(exports, '__esModule', {
123
123
  value: true
124
124
  });
@@ -1,4 +1,4 @@
1
- export interface CgnResolverOptions {
1
+ export interface VantResolverOptions {
2
2
  /**
3
3
  * Whether to automatically import the corresponding styles of the components.
4
4
  *
@@ -24,8 +24,8 @@ export interface CgnResolverOptions {
24
24
  */
25
25
  exclude?: string[];
26
26
  }
27
- export type CgnImportsOptions = Pick<CgnResolverOptions, 'module' | 'ssr'>;
28
- export declare function CgnResolver(options?: CgnResolverOptions): {
27
+ export type VantImportsOptions = Pick<VantResolverOptions, 'module' | 'ssr'>;
28
+ export declare function VantResolver(options?: VantResolverOptions): {
29
29
  type: "component";
30
30
  resolve: (name: string) => {
31
31
  name: string;
@@ -33,6 +33,6 @@ export declare function CgnResolver(options?: CgnResolverOptions): {
33
33
  sideEffects: string | undefined;
34
34
  } | undefined;
35
35
  };
36
- export declare function CgnImports(options?: CgnImportsOptions): {
36
+ export declare function VantImports(options?: VantImportsOptions): {
37
37
  [x: string]: string[];
38
38
  };
@@ -51,23 +51,21 @@ function getAPIMap() {
51
51
  });
52
52
  return apiMap;
53
53
  }
54
- function CgnResolver(options = {}) {
54
+ function VantResolver(options = {}) {
55
55
  const moduleType = getModuleType(options);
56
56
  const apiMap = getAPIMap();
57
57
  return {
58
58
  type: 'component',
59
59
  resolve: (name)=>{
60
- var _options_exclude;
61
60
  if (name.startsWith('Cgn')) {
62
- var _options_exclude1;
63
61
  const partialName = name.slice(3);
64
- if (!(null === (_options_exclude1 = options.exclude) || void 0 === _options_exclude1 ? void 0 : _options_exclude1.includes(partialName))) return {
62
+ if (!options.exclude?.includes(partialName)) return {
65
63
  name: partialName,
66
64
  from: `cgn-vant/${moduleType}`,
67
65
  sideEffects: getSideEffects(kebabCase(partialName), options)
68
66
  };
69
67
  }
70
- if (apiMap.has(name) && !(null === (_options_exclude = options.exclude) || void 0 === _options_exclude ? void 0 : _options_exclude.includes(name))) {
68
+ if (apiMap.has(name) && !options.exclude?.includes(name)) {
71
69
  const partialName = apiMap.get(name);
72
70
  return {
73
71
  name,
@@ -78,7 +76,7 @@ function CgnResolver(options = {}) {
78
76
  }
79
77
  };
80
78
  }
81
- function CgnImports(options = {}) {
79
+ function VantImports(options = {}) {
82
80
  const moduleType = getModuleType(options);
83
81
  return {
84
82
  [`cgn-vant/${moduleType}`]: [
@@ -86,4 +84,4 @@ function CgnImports(options = {}) {
86
84
  ]
87
85
  };
88
86
  }
89
- export { CgnImports, CgnResolver };
87
+ export { VantImports, VantResolver };
@@ -2,7 +2,7 @@
2
2
  "name": "auto-import-resolver",
3
3
  "version": "1.3.0",
4
4
  "type": "module",
5
- "description": "CGN-Vant auto import resolver based on unplugin-vue-components",
5
+ "description": "CgnUI auto import resolver based on unplugin-vue-components",
6
6
  "main": "dist/index.cjs",
7
7
  "module": "dist/index.js",
8
8
  "typings": "dist/index.d.ts",
package/es/index.d.ts CHANGED
@@ -106,4 +106,4 @@ declare namespace _default {
106
106
  }
107
107
  export default _default;
108
108
  export function install(app: any): void;
109
- export const version: "1.0.7";
109
+ export const version: "1.0.0";
package/es/index.mjs CHANGED
@@ -99,7 +99,7 @@ import { Toast } from "./toast/index.mjs";
99
99
  import { TreeSelect } from "./tree-select/index.mjs";
100
100
  import { Uploader } from "./uploader/index.mjs";
101
101
  import { Watermark } from "./watermark/index.mjs";
102
- const version = "1.0.7";
102
+ const version = "1.0.0";
103
103
  function install(app) {
104
104
  const components = [
105
105
  ActionBar,
@@ -17136,7 +17136,7 @@ const Lazyload = {
17136
17136
  });
17137
17137
  }
17138
17138
  };
17139
- const version = "1.0.7";
17139
+ const version = "1.0.0";
17140
17140
  function install(app) {
17141
17141
  const components = [
17142
17142
  ActionBar,
@@ -17134,7 +17134,7 @@ const Lazyload = {
17134
17134
  });
17135
17135
  }
17136
17136
  };
17137
- const version = "1.0.7";
17137
+ const version = "1.0.0";
17138
17138
  function install(app) {
17139
17139
  const components = [
17140
17140
  ActionBar,
@@ -1,5 +1,5 @@
1
1
  (function(global, factory) {
2
- typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("vue")) : typeof define === "function" && define.amd ? define(["exports", "vue"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.vant = {}, global.Vue));
2
+ typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("vue")) : typeof define === "function" && define.amd ? define(["exports", "vue"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global["cgn-vant"] = {}, global.Vue));
3
3
  })(this, function(exports2, vue) {
4
4
  "use strict";
5
5
  function noop() {
@@ -18253,7 +18253,7 @@
18253
18253
  });
18254
18254
  }
18255
18255
  };
18256
- const version = "1.0.7";
18256
+ const version = "1.0.0";
18257
18257
  function install(app) {
18258
18258
  const components = [
18259
18259
  ActionBar,