@ciwergrp/nuxid 1.5.9 → 1.5.11
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/dist/module.json +1 -1
- package/dist/runtime/helper/index.d.ts +1 -1
- package/dist/runtime/helper/index.js +0 -3
- package/dist/runtime/helper/string/index.d.ts +1 -5
- package/dist/runtime/helper/string/index.js +0 -7
- package/package.json +1 -2
- package/dist/runtime/helper/string/plural.d.ts +0 -3
- package/dist/runtime/helper/string/plural.js +0 -17
package/dist/module.json
CHANGED
|
@@ -9,7 +9,7 @@ export type { NumberHelper } from './number/index.js';
|
|
|
9
9
|
export { abbreviate, forHumans, clamp, currency, fileSize, format, ordinal, pairs, parse, parseFloatNumber, parseIntNumber, percentage, spell, spellOrdinal, trim, } from './number/index.js';
|
|
10
10
|
export { string } from './string/index.js';
|
|
11
11
|
export type { StringHelper } from './string/index.js';
|
|
12
|
-
export { after, afterLast, ascii, before, beforeLast, between, betweenFirst, camel, contains, containsAll, endsWith, finish, kebab, lcfirst, length, lower, padBoth, padLeft, padRight,
|
|
12
|
+
export { after, afterLast, ascii, before, beforeLast, between, betweenFirst, camel, contains, containsAll, endsWith, finish, kebab, lcfirst, length, lower, padBoth, padLeft, padRight, remove, replace, replaceFirst, replaceLast, rtrim, slug, snake, start, startsWith, studly, title, transliterate, ucfirst, upper, wordCount, words, } from './string/index.js';
|
|
13
13
|
export { defaultLocale, useLocale, withLocale, defaultCurrency, useCurrency, withCurrency, } from './state.js';
|
|
14
14
|
export { dt } from './date/index.js';
|
|
15
15
|
export type { DateHelper, DateInput, DateFormatPreset } from './date/index.js';
|
|
@@ -4,7 +4,6 @@ import { camel, kebab, lcfirst, lower, snake, studly, title, ucfirst, upper } fr
|
|
|
4
4
|
import { contains, containsAll, endsWith, startsWith } from './match.js';
|
|
5
5
|
import { defaultLocale, useLocale, withLocale } from './locale.js';
|
|
6
6
|
import { padBoth, padLeft, padRight } from './pad.js';
|
|
7
|
-
import { plural, pluralStudly, singular } from './plural.js';
|
|
8
7
|
import { remove, replace, replaceFirst, replaceLast } from './replace.js';
|
|
9
8
|
import { slug } from './slug.js';
|
|
10
9
|
import { ascii, transliterate } from './transliterate.js';
|
|
@@ -31,14 +30,11 @@ export interface StringHelper {
|
|
|
31
30
|
padBoth: typeof padBoth;
|
|
32
31
|
padLeft: typeof padLeft;
|
|
33
32
|
padRight: typeof padRight;
|
|
34
|
-
plural: typeof plural;
|
|
35
|
-
pluralStudly: typeof pluralStudly;
|
|
36
33
|
remove: typeof remove;
|
|
37
34
|
replace: typeof replace;
|
|
38
35
|
replaceFirst: typeof replaceFirst;
|
|
39
36
|
replaceLast: typeof replaceLast;
|
|
40
37
|
rtrim: typeof rtrim;
|
|
41
|
-
singular: typeof singular;
|
|
42
38
|
slug: typeof slug;
|
|
43
39
|
snake: typeof snake;
|
|
44
40
|
start: typeof start;
|
|
@@ -54,4 +50,4 @@ export interface StringHelper {
|
|
|
54
50
|
withLocale: typeof withLocale;
|
|
55
51
|
}
|
|
56
52
|
export declare function string(): StringHelper;
|
|
57
|
-
export { after, afterLast, ascii, before, beforeLast, between, betweenFirst, defaultLocale, camel, contains, containsAll, endsWith, finish, kebab, lcfirst, length, lower, padBoth, padLeft, padRight,
|
|
53
|
+
export { after, afterLast, ascii, before, beforeLast, between, betweenFirst, defaultLocale, camel, contains, containsAll, endsWith, finish, kebab, lcfirst, length, lower, padBoth, padLeft, padRight, remove, replace, replaceFirst, replaceLast, rtrim, slug, snake, start, startsWith, studly, title, transliterate, ucfirst, upper, wordCount, words, useLocale, withLocale, };
|
|
@@ -4,7 +4,6 @@ import { camel, kebab, lcfirst, lower, snake, studly, title, ucfirst, upper } fr
|
|
|
4
4
|
import { contains, containsAll, endsWith, startsWith } from "./match.js";
|
|
5
5
|
import { defaultLocale, useLocale, withLocale } from "./locale.js";
|
|
6
6
|
import { padBoth, padLeft, padRight } from "./pad.js";
|
|
7
|
-
import { plural, pluralStudly, singular } from "./plural.js";
|
|
8
7
|
import { remove, replace, replaceFirst, replaceLast } from "./replace.js";
|
|
9
8
|
import { slug } from "./slug.js";
|
|
10
9
|
import { ascii, transliterate } from "./transliterate.js";
|
|
@@ -32,14 +31,11 @@ export function string() {
|
|
|
32
31
|
padBoth,
|
|
33
32
|
padLeft,
|
|
34
33
|
padRight,
|
|
35
|
-
plural,
|
|
36
|
-
pluralStudly,
|
|
37
34
|
remove,
|
|
38
35
|
replace,
|
|
39
36
|
replaceFirst,
|
|
40
37
|
replaceLast,
|
|
41
38
|
rtrim,
|
|
42
|
-
singular,
|
|
43
39
|
slug,
|
|
44
40
|
snake,
|
|
45
41
|
start,
|
|
@@ -76,14 +72,11 @@ export {
|
|
|
76
72
|
padBoth,
|
|
77
73
|
padLeft,
|
|
78
74
|
padRight,
|
|
79
|
-
plural,
|
|
80
|
-
pluralStudly,
|
|
81
75
|
remove,
|
|
82
76
|
replace,
|
|
83
77
|
replaceFirst,
|
|
84
78
|
replaceLast,
|
|
85
79
|
rtrim,
|
|
86
|
-
singular,
|
|
87
80
|
slug,
|
|
88
81
|
snake,
|
|
89
82
|
start,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ciwergrp/nuxid",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.11",
|
|
4
4
|
"description": "All-in-one essential modules for Nuxt",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -59,7 +59,6 @@
|
|
|
59
59
|
"hls.js": "1.6.15",
|
|
60
60
|
"lodash-es": "4.17.22",
|
|
61
61
|
"pinia": "3.0.4",
|
|
62
|
-
"pluralize": "8.0.0",
|
|
63
62
|
"socket.io-client": "4.8.3"
|
|
64
63
|
},
|
|
65
64
|
"devDependencies": {
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import pluralizeModule from "pluralize";
|
|
2
|
-
import { studly } from "./case.js";
|
|
3
|
-
const pluralize = pluralizeModule.default ?? pluralizeModule;
|
|
4
|
-
export function plural(value, count) {
|
|
5
|
-
if (typeof count === "number") {
|
|
6
|
-
return pluralize(value, count);
|
|
7
|
-
}
|
|
8
|
-
return pluralize(value);
|
|
9
|
-
}
|
|
10
|
-
export function singular(value) {
|
|
11
|
-
return pluralize.singular(value);
|
|
12
|
-
}
|
|
13
|
-
export function pluralStudly(value, count) {
|
|
14
|
-
const studlyValue = studly(value);
|
|
15
|
-
const inflected = plural(studlyValue, count);
|
|
16
|
-
return count === 1 ? studlyValue : inflected;
|
|
17
|
-
}
|