@tolki/str 1.0.10 → 1.0.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/README.md CHANGED
@@ -1,3 +1,5 @@
1
+ <p align="center"><img src="https://raw.githubusercontent.com/abetwothree/laravel-ts-publish/refs/heads/main/assets/laravel-typescript-publish-logo-short.svg" width="50%" alt="Laravel Tolki JS Logo"></p>
2
+
1
3
  # Tolki JS Str Package
2
4
 
3
5
  This package provides string utility functions similar to Laravel's Str class facade.
package/dist/index.js CHANGED
@@ -2,23 +2,23 @@ import { ascii as t, slug as a } from "./ascii/index.js";
2
2
  import { bytesToBase64 as i, fromBase64 as o, toBase64 as n } from "./base64/index.js";
3
3
  import { CaseTypes as c, convertCase as p, title as d, upper as u } from "./convertcase/index.js";
4
4
  import { inlineMarkdown as f, markDownRenderer as h, markdown as g } from "./markdown/index.js";
5
- import { inflector as U, isPlural as w, isSingular as x, matchCase as b, plural as C, pluralPascal as k, pluralStudly as y, singular as R, uncountable as z } from "./pluralizer/index.js";
5
+ import { inflector as U, isPlural as w, isSingular as x, matchCase as b, plural as y, pluralPascal as C, pluralStudly as k, singular as R, uncountable as z } from "./pluralizer/index.js";
6
6
  import { randomInt as W, randomString as q } from "./random/index.js";
7
7
  import { substr as L, substrCount as v, substrReplace as E } from "./replacer/index.js";
8
- import { after as N, afterLast as P, apa as T, before as F, beforeLast as D, between as I, betweenFirst as J, camel as O, camelCacheSize as j, charAt as G, chopEnd as H, chopStart as K, contains as Q, containsAll as V, createRandomStringsNormally as X, createRandomStringsUsing as Y, createRandomStringsUsingSequence as Z, deduplicate as _, doesntContain as $, doesntEndWith as ee, doesntStartWith as re, endsWith as te, excerpt as ae, finish as se, flushCache as ie, headline as oe, initials as ne, is as le, isAscii as ce, isJson as pe, isMatch as de, isUrl as ue, kebab as me, lcfirst as fe, length as he, limit as ge, lower as Se, makePad as Ue, mask as we, match as xe, matchAll as be, numbers as Ce, padBoth as ke, padLeft as ye, padRight as Re, pascal as ze, password as Ae, position as We, random as qe, remove as Be, repeat as Le, replace as ve, replaceArray as Ee, replaceEnd as Me, replaceFirst as Ne, replaceLast as Pe, replaceMatches as Te, replaceStart as Fe, reverse as De, snake as Ie, snakeCacheSize as Je, squish as Oe, start as je, startsWith as Ge, stripTags as He, studly as Ke, studlyCacheSize as Qe, swap as Ve, take as Xe, toStringOr as Ye, ucfirst as Ze, ucsplit as _e, ucwords as $e, unwrap as er, wordCount as rr, wordWrap as tr, words as ar, wrap as sr } from "./str.js";
9
- import { Stringable as or, of as nr, str as lr } from "./stringable/index.js";
10
- import { transliterate as pr } from "./transliterate/index.js";
11
- import { ltrim as ur, rtrim as mr, trim as fr } from "./trimmer/index.js";
12
- import { createUlidsNormally as gr, createUlidsUsing as Sr, createUlidsUsingSequence as Ur, freezeUlids as wr, isUlid as xr, ulid as br } from "./ulid/index.js";
13
- import { createUuidsNormally as kr, createUuidsUsing as yr, createUuidsUsingSequence as Rr, freezeUuids as zr, isUuid as Ar, uuid as Wr, uuid7 as qr } from "./uuid/index.js";
8
+ import { after as M, afterLast as N, apa as P, before as T, beforeLast as D, between as I, betweenFirst as J, camel as O, camelCacheSize as j, charAt as G, chopEnd as H, chopStart as K, contains as Q, containsAll as V, createRandomStringsNormally as X, createRandomStringsUsing as Y, createRandomStringsUsingSequence as Z, deduplicate as _, doesntContain as $, doesntEndWith as ee, doesntStartWith as re, endsWith as te, excerpt as ae, finish as se, flushCache as ie, headline as oe, initials as ne, is as le, isAscii as ce, isJson as pe, isMatch as de, isUrl as ue, kebab as me, lcfirst as fe, length as he, limit as ge, lower as Se, makePad as Ue, mask as we, match as xe, matchAll as be, numbers as ye, padBoth as Ce, padLeft as ke, padRight as Re, pascal as ze, password as Ae, position as We, random as qe, remove as Be, repeat as Le, replace as ve, replaceArray as Ee, replaceEnd as Fe, replaceFirst as Me, replaceLast as Ne, replaceMatches as Pe, replaceStart as Te, resetFactoryState as De, reverse as Ie, snake as Je, snakeCacheSize as Oe, squish as je, start as Ge, startsWith as He, stripTags as Ke, studly as Qe, studlyCacheSize as Ve, swap as Xe, take as Ye, toStringOr as Ze, ucfirst as _e, ucsplit as $e, ucwords as er, unwrap as rr, wordCount as tr, wordWrap as ar, words as sr, wrap as ir } from "./str.js";
9
+ import { Stringable as nr, of as lr, str as cr } from "./stringable/index.js";
10
+ import { transliterate as dr } from "./transliterate/index.js";
11
+ import { ltrim as mr, rtrim as fr, trim as hr } from "./trimmer/index.js";
12
+ import { createUlidsNormally as Sr, createUlidsUsing as Ur, createUlidsUsingSequence as wr, freezeUlids as xr, isUlid as br, ulid as yr } from "./ulid/index.js";
13
+ import { createUuidsNormally as kr, createUuidsUsing as Rr, createUuidsUsingSequence as zr, freezeUuids as Ar, isUuid as Wr, uuid as qr, uuid7 as Br } from "./uuid/index.js";
14
14
  export {
15
15
  c as CaseTypes,
16
- or as Stringable,
17
- N as after,
18
- P as afterLast,
19
- T as apa,
16
+ nr as Stringable,
17
+ M as after,
18
+ N as afterLast,
19
+ P as apa,
20
20
  t as ascii,
21
- F as before,
21
+ T as before,
22
22
  D as beforeLast,
23
23
  I as between,
24
24
  J as betweenFirst,
@@ -34,12 +34,12 @@ export {
34
34
  X as createRandomStringsNormally,
35
35
  Y as createRandomStringsUsing,
36
36
  Z as createRandomStringsUsingSequence,
37
- gr as createUlidsNormally,
38
- Sr as createUlidsUsing,
39
- Ur as createUlidsUsingSequence,
37
+ Sr as createUlidsNormally,
38
+ Ur as createUlidsUsing,
39
+ wr as createUlidsUsingSequence,
40
40
  kr as createUuidsNormally,
41
- yr as createUuidsUsing,
42
- Rr as createUuidsUsingSequence,
41
+ Rr as createUuidsUsing,
42
+ zr as createUuidsUsingSequence,
43
43
  _ as deduplicate,
44
44
  $ as doesntContain,
45
45
  ee as doesntEndWith,
@@ -48,8 +48,8 @@ export {
48
48
  ae as excerpt,
49
49
  se as finish,
50
50
  ie as flushCache,
51
- wr as freezeUlids,
52
- zr as freezeUuids,
51
+ xr as freezeUlids,
52
+ Ar as freezeUuids,
53
53
  o as fromBase64,
54
54
  oe as headline,
55
55
  U as inflector,
@@ -61,15 +61,15 @@ export {
61
61
  de as isMatch,
62
62
  w as isPlural,
63
63
  x as isSingular,
64
- xr as isUlid,
64
+ br as isUlid,
65
65
  ue as isUrl,
66
- Ar as isUuid,
66
+ Wr as isUuid,
67
67
  me as kebab,
68
68
  fe as lcfirst,
69
69
  he as length,
70
70
  ge as limit,
71
71
  Se as lower,
72
- ur as ltrim,
72
+ mr as ltrim,
73
73
  Ue as makePad,
74
74
  h as markDownRenderer,
75
75
  g as markdown,
@@ -77,16 +77,16 @@ export {
77
77
  xe as match,
78
78
  be as matchAll,
79
79
  b as matchCase,
80
- Ce as numbers,
81
- nr as of,
82
- ke as padBoth,
83
- ye as padLeft,
80
+ ye as numbers,
81
+ lr as of,
82
+ Ce as padBoth,
83
+ ke as padLeft,
84
84
  Re as padRight,
85
85
  ze as pascal,
86
86
  Ae as password,
87
- C as plural,
88
- k as pluralPascal,
89
- y as pluralStudly,
87
+ y as plural,
88
+ C as pluralPascal,
89
+ k as pluralStudly,
90
90
  We as position,
91
91
  qe as random,
92
92
  W as randomInt,
@@ -95,45 +95,46 @@ export {
95
95
  Le as repeat,
96
96
  ve as replace,
97
97
  Ee as replaceArray,
98
- Me as replaceEnd,
99
- Ne as replaceFirst,
100
- Pe as replaceLast,
101
- Te as replaceMatches,
102
- Fe as replaceStart,
103
- De as reverse,
104
- mr as rtrim,
98
+ Fe as replaceEnd,
99
+ Me as replaceFirst,
100
+ Ne as replaceLast,
101
+ Pe as replaceMatches,
102
+ Te as replaceStart,
103
+ De as resetFactoryState,
104
+ Ie as reverse,
105
+ fr as rtrim,
105
106
  R as singular,
106
107
  a as slug,
107
- Ie as snake,
108
- Je as snakeCacheSize,
109
- Oe as squish,
110
- je as start,
111
- Ge as startsWith,
112
- lr as str,
113
- He as stripTags,
114
- Ke as studly,
115
- Qe as studlyCacheSize,
108
+ Je as snake,
109
+ Oe as snakeCacheSize,
110
+ je as squish,
111
+ Ge as start,
112
+ He as startsWith,
113
+ cr as str,
114
+ Ke as stripTags,
115
+ Qe as studly,
116
+ Ve as studlyCacheSize,
116
117
  L as substr,
117
118
  v as substrCount,
118
119
  E as substrReplace,
119
- Ve as swap,
120
- Xe as take,
120
+ Xe as swap,
121
+ Ye as take,
121
122
  d as title,
122
123
  n as toBase64,
123
- Ye as toStringOr,
124
- pr as transliterate,
125
- fr as trim,
126
- Ze as ucfirst,
127
- _e as ucsplit,
128
- $e as ucwords,
129
- br as ulid,
124
+ Ze as toStringOr,
125
+ dr as transliterate,
126
+ hr as trim,
127
+ _e as ucfirst,
128
+ $e as ucsplit,
129
+ er as ucwords,
130
+ yr as ulid,
130
131
  z as uncountable,
131
- er as unwrap,
132
+ rr as unwrap,
132
133
  u as upper,
133
- Wr as uuid,
134
- qr as uuid7,
135
- rr as wordCount,
136
- tr as wordWrap,
137
- ar as words,
138
- sr as wrap
134
+ qr as uuid,
135
+ Br as uuid7,
136
+ tr as wordCount,
137
+ ar as wordWrap,
138
+ sr as words,
139
+ ir as wrap
139
140
  };
package/dist/str.d.ts CHANGED
@@ -809,4 +809,10 @@ export declare function studlyCacheSize(): number;
809
809
  * @returns void
810
810
  */
811
811
  export declare function flushCache(): void;
812
+ /**
813
+ * Return all factory functions to their default state.
814
+ *
815
+ * @returns void
816
+ */
817
+ export declare function resetFactoryState(): void;
812
818
  //# sourceMappingURL=str.d.ts.map
package/dist/str.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"str.d.ts","sourceRoot":"","sources":["../src/str.ts"],"names":[],"mappings":"AA2BA;;;;;;;;GAQG;AACH,wBAAgB,KAAK,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAatE;AAED;;;;;;;;GAQG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,M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C;AAED;;;;;;;GAOG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAE7C;AAED;;;;;;;GAOG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAE/C;AAED;;;;;;;;GAQG;AACH,wBAAgB,OAAO,CACnB,KAAK,EAAE,MAAM,EACb,UAAU,GAAE,MAAM,GAAG,MAAM,EAAkB,GAC9C,MAAM,CAcR;AAED;;;;;;;;GAQG;AACH,wBAAgB,SAAS,CACrB,KAAK,EAAE,MAAM,EACb,UAAU,GAAE,MAAM,GAAG,IAAW,GACjC,MAAM,CAcR;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,QAAQ,CACpB,KAAK,EAAE,MAAM,EACb,UAAU,GAAE,MAAW,EACvB,QAAQ,GAAE,MAAa,EACvB,YAAY,GAAE,OAAe,GAC9B,MAAM,CAqFR;AAED;;;;;;;;GAQG;AACH,wBAAgB,cAAc,IAAI,MAAM,CAEvC;AAED;;;;;;;;GAQG;AACH,wBAAgB,cAAc,IAAI,MAAM,CAEvC;AAED;;;;;;;;GAQG;AACH,wBAAgB,eAAe,IAAI,MAAM,CAExC;AAED;;;;GAIG;AACH,wBAAgB,UAAU,IAAI,IAAI,CAIjC;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,IAAI,IAAI,CAIxC"}
package/dist/str.js CHANGED
@@ -1,8 +1,10 @@
1
- import { isArray as x, toLower as W, isString as _, isFunction as Z, isNumber as j } from "@tolki/utils";
1
+ import { isArray as S, toLower as U, isString as _, isFunction as Z, isNumber as j } from "@tolki/utils";
2
2
  import { title as I, upper as T } from "./convertcase/index.js";
3
3
  import { randomInt as O, randomString as D } from "./random/index.js";
4
- import { substr as S } from "./replacer/index.js";
4
+ import { substr as x } from "./replacer/index.js";
5
5
  import { ltrim as q, rtrim as G, trim as Q } from "./trimmer/index.js";
6
+ import { createUlidsNormally as V } from "./ulid/index.js";
7
+ import { createUuidsNormally as X } from "./uuid/index.js";
6
8
  const R = /* @__PURE__ */ new Map(), C = /* @__PURE__ */ new Map(), F = /* @__PURE__ */ new Map();
7
9
  let L = null;
8
10
  function B(t, e) {
@@ -11,50 +13,50 @@ function B(t, e) {
11
13
  const n = String(e), r = t.indexOf(n);
12
14
  return r === -1 ? t : t.slice(r + n.length);
13
15
  }
14
- function gt(t, e) {
16
+ function wt(t, e) {
15
17
  if (e === "")
16
18
  return t;
17
19
  const n = t.lastIndexOf(String(e));
18
20
  return n === -1 ? t : t.slice(n + String(e).length);
19
21
  }
20
- function V(t, e) {
22
+ function Y(t, e) {
21
23
  if (e === "")
22
24
  return t;
23
25
  const n = t.indexOf(String(e));
24
26
  return n === -1 ? t : t.slice(0, n);
25
27
  }
26
- function X(t, e) {
28
+ function v(t, e) {
27
29
  if (e === "")
28
30
  return t;
29
31
  const n = t.lastIndexOf(String(e));
30
- return n === -1 ? t : S(t, 0, n);
32
+ return n === -1 ? t : x(t, 0, n);
31
33
  }
32
- function mt(t, e, n) {
33
- return e === "" || n === "" ? t : X(B(t, e), n);
34
+ function St(t, e, n) {
35
+ return e === "" || n === "" ? t : v(B(t, e), n);
34
36
  }
35
- function ht(t, e, n) {
36
- return e === "" || n === "" ? t : V(B(t, e), n);
37
+ function xt(t, e, n) {
38
+ return e === "" || n === "" ? t : Y(B(t, e), n);
37
39
  }
38
- function dt(t) {
40
+ function $t(t) {
39
41
  if (C.has(t))
40
42
  return C.get(t);
41
- const e = st(K(t));
43
+ const e = ct(K(t));
42
44
  return C.set(t, e), e;
43
45
  }
44
- function yt(t, e) {
46
+ function kt(t, e) {
45
47
  const n = t.length;
46
48
  return (e < 0 ? e < -n : e > n - 1) ? !1 : (e < 0 && (e += n), t.charAt(e));
47
49
  }
48
- function wt(t, e) {
49
- for (const n of x(e) ? e : [e])
50
+ function At(t, e) {
51
+ for (const n of S(e) ? e : [e])
50
52
  if (n !== "" && t.startsWith(n)) {
51
53
  const r = [...t], s = [...n];
52
54
  return r.slice(s.length).join("");
53
55
  }
54
56
  return t;
55
57
  }
56
- function xt(t, e) {
57
- for (const n of x(e) ? e : [e])
58
+ function bt(t, e) {
59
+ for (const n of S(e) ? e : [e])
58
60
  if (n !== "" && t.endsWith(n)) {
59
61
  const r = [...t], s = [...n];
60
62
  return r.slice(0, -s.length).join("");
@@ -70,59 +72,59 @@ function H(t, e, n = !1) {
70
72
  return !0;
71
73
  return !1;
72
74
  }
73
- function St(t, e = "", n = {}) {
75
+ function Et(t, e = "", n = {}) {
74
76
  const { radius: r = 100, omission: s = "..." } = n, o = String(t ?? ""), c = e ?? "", i = ($) => $.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), l = new RegExp(`^(.*?)(${i(c)})(.*)$`, "iu").exec(o);
75
77
  if (!l)
76
78
  return null;
77
- const p = String(l[1]), a = String(l[2]), g = String(l[3]), u = q(p), m = Array.from(u).length, y = S(u, Math.max(m - r, 0), r);
79
+ const p = String(l[1]), a = String(l[2]), g = String(l[3]), u = q(p), m = Array.from(u).length, y = x(u, Math.max(m - r, 0), r);
78
80
  let w = q(y);
79
81
  w !== u && (w = s + w);
80
- const h = G(g), d = S(h, 0, r);
82
+ const h = G(g), d = x(h, 0, r);
81
83
  let k = G(d);
82
84
  return k !== h && (k = k + s), w + a + k;
83
85
  }
84
- function $t(t, e, n = !1) {
86
+ function Lt(t, e, n = !1) {
85
87
  for (const r of e)
86
88
  if (!H(t, r, n))
87
89
  return !1;
88
90
  return !0;
89
91
  }
90
- function kt(t, e, n = !1) {
92
+ function Rt(t, e, n = !1) {
91
93
  return !H(t, e, n);
92
94
  }
93
- function At(t, e = " ") {
94
- return x(e) ? (e.forEach((n) => {
95
+ function Ct(t, e = " ") {
96
+ return S(e) ? (e.forEach((n) => {
95
97
  t = t.replace(new RegExp(`${n}+`, "g"), n);
96
98
  }), t) : t.replace(new RegExp(`${e}+`, "g"), e);
97
99
  }
98
- function M(t, e) {
100
+ function W(t, e) {
99
101
  if (t === null)
100
102
  return !1;
101
- t = String(t), x(e) ? e = Array.from(e) : e = [String(e)];
103
+ t = String(t), S(e) ? e = Array.from(e) : e = [String(e)];
102
104
  for (const n of e)
103
105
  if (n !== "" && t.endsWith(n))
104
106
  return !0;
105
107
  return !1;
106
108
  }
107
- function bt(t, e) {
108
- return !M(t, e);
109
+ function Ft(t, e) {
110
+ return !W(t, e);
109
111
  }
110
- function Et(t, e) {
112
+ function Nt(t, e) {
111
113
  const n = e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
112
114
  return t.replace(new RegExp(`(?:${n})+$`, "u"), "") + e;
113
115
  }
114
- function Lt(t, e, n = null) {
116
+ function zt(t, e, n = null) {
115
117
  return e + t + (n ?? e);
116
118
  }
117
- function Rt(t, e, n = null) {
118
- return U(t, e) && (t = S(t, z(e))), M(t, n ??= e) && (t = S(t, 0, -z(n))), t;
119
+ function _t(t, e, n = null) {
120
+ return M(t, e) && (t = x(t, N(e))), W(t, n ??= e) && (t = x(t, 0, -N(n))), t;
119
121
  }
120
- function Ct(t, e, n = !1) {
122
+ function Ot(t, e, n = !1) {
121
123
  e = String(e);
122
124
  let r;
123
125
  typeof t == "string" ? r = [t] : r = Array.from(t);
124
126
  for (let s of r) {
125
- if (s = String(s), s === e || n && W(s) === W(e))
127
+ if (s = String(s), s === e || n && U(s) === U(e))
126
128
  return !0;
127
129
  s = s.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), s = s.replace(/\\\*/g, ".*");
128
130
  const o = n ? "iu" : "u";
@@ -131,13 +133,13 @@ function Ct(t, e, n = !1) {
131
133
  }
132
134
  return !1;
133
135
  }
134
- function Ft(t) {
136
+ function Ut(t) {
135
137
  for (let e = 0; e < t.length; e++)
136
138
  if (t.charCodeAt(e) > 127)
137
139
  return !1;
138
140
  return !0;
139
141
  }
140
- function zt(t) {
142
+ function Wt(t) {
141
143
  if (!_(t))
142
144
  return !1;
143
145
  try {
@@ -147,7 +149,7 @@ function zt(t) {
147
149
  }
148
150
  return !0;
149
151
  }
150
- function Nt(t, e = []) {
152
+ function Mt(t, e = []) {
151
153
  if (!_(t))
152
154
  return !1;
153
155
  const r = (e.length === 0 ? "aaa|aaas|about|acap|acct|acd|acr|adiumxtra|adt|afp|afs|aim|amss|android|appdata|apt|ark|attachment|aw|barion|beshare|bitcoin|bitcoincash|blob|bolo|browserext|calculator|callto|cap|cast|casts|chrome|chrome-extension|cid|coap|coap+tcp|coap+ws|coaps|coaps+tcp|coaps+ws|com-eventbrite-attendee|content|conti|crid|cvs|dab|data|dav|diaspora|dict|did|dis|dlna-playcontainer|dlna-playsingle|dns|dntp|dpp|drm|drop|dtn|dvb|ed2k|elsi|example|facetime|fax|feed|feedready|file|filesystem|finger|first-run-pen-experience|fish|fm|ftp|fuchsia-pkg|geo|gg|git|gizmoproject|go|gopher|graph|gtalk|h323|ham|hcap|hcp|http|https|hxxp|hxxps|hydrazone|iax|icap|icon|im|imap|info|iotdisco|ipn|ipp|ipps|irc|irc6|ircs|iris|iris.beep|iris.lwz|iris.xpc|iris.xpcs|isostore|itms|jabber|jar|jms|keyparc|lastfm|ldap|ldaps|leaptofrogans|lorawan|lvlt|magnet|mailserver|mailto|maps|market|message|mid|mms|modem|mongodb|moz|ms-access|ms-browser-extension|ms-calculator|ms-drive-to|ms-enrollment|ms-excel|ms-eyecontrolspeech|ms-gamebarservices|ms-gamingoverlay|ms-getoffice|ms-help|ms-infopath|ms-inputapp|ms-lockscreencomponent-config|ms-media-stream-id|ms-mixedrealitycapture|ms-mobileplans|ms-officeapp|ms-people|ms-project|ms-powerpoint|ms-publisher|ms-restoretabcompanion|ms-screenclip|ms-screensketch|ms-search|ms-search-repair|ms-secondary-screen-controller|ms-secondary-screen-setup|ms-settings|ms-settings-airplanemode|ms-settings-bluetooth|ms-settings-camera|ms-settings-cellular|ms-settings-cloudstorage|ms-settings-connectabledevices|ms-settings-displays-topology|ms-settings-emailandaccounts|ms-settings-language|ms-settings-location|ms-settings-lock|ms-settings-nfctransactions|ms-settings-notifications|ms-settings-power|ms-settings-privacy|ms-settings-proximity|ms-settings-screenrotation|ms-settings-wifi|ms-settings-workplace|ms-spd|ms-sttoverlay|ms-transit-to|ms-useractivityset|ms-virtualtouchpad|ms-visio|ms-walk-to|ms-whiteboard|ms-whiteboard-cmd|ms-word|msnim|msrp|msrps|mss|mtqp|mumble|mupdate|mvn|news|nfs|ni|nih|nntp|notes|ocf|oid|onenote|onenote-cmd|opaquelocktoken|openpgp4fpr|pack|palm|paparazzi|payto|pkcs11|platform|pop|pres|prospero|proxy|pwid|psyc|pttp|qb|query|redis|rediss|reload|res|resource|rmi|rsync|rtmfp|rtmp|rtsp|rtsps|rtspu|s3|secondlife|service|session|sftp|sgn|shttp|sieve|simpleledger|sip|sips|skype|smb|sms|smtp|snews|snmp|soap.beep|soap.beeps|soldat|spiffe|spotify|ssh|steam|stun|stuns|submit|svn|tag|teamspeak|tel|teliaeid|telnet|tftp|tg|things|thismessage|tip|tn3270|tool|ts3server|turn|turns|tv|udp|unreal|urn|ut2004|v-event|vemmi|ventrilo|videotex|vnc|view-source|wais|webcal|wpid|ws|wss|wtai|wyciwyg|xcon|xcon-userid|xfire|xmlrpc.beep|xmlrpc.beeps|xmpp|xri|ymsgr|z39.50|z39.50r|z39.50s" : e.join("|")).split("|").map((o) => o.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")).join("|");
@@ -177,31 +179,31 @@ function Nt(t, e = []) {
177
179
  ].join("");
178
180
  return new RegExp(s, "iu").test(t);
179
181
  }
180
- function _t(t) {
181
- return rt(t, "-");
182
+ function Pt(t) {
183
+ return it(t, "-");
182
184
  }
183
- function z(t) {
185
+ function N(t) {
184
186
  return t.length;
185
187
  }
186
- function Ot(t, e = 100, n = "...", r = !1) {
188
+ function It(t, e = 100, n = "...", r = !1) {
187
189
  if (t.length <= e)
188
190
  return t;
189
191
  if (!r)
190
192
  return t.slice(0, e).replace(/\s+$/, "") + n;
191
- t = nt(t).replace(/[\n\r]+/g, " ").trim();
193
+ t = ot(t).replace(/[\n\r]+/g, " ").trim();
192
194
  const s = t.slice(0, e).replace(/\s+$/, "");
193
195
  return t.substring(e, e + 1) === " " ? s + n : s.replace(/(.*)\s.*/, "$1") + n;
194
196
  }
195
197
  function J(t) {
196
- return W(t);
198
+ return U(t);
197
199
  }
198
- function Wt(t, e = 100, n = "...") {
200
+ function qt(t, e = 100, n = "...") {
199
201
  if (e <= 0)
200
202
  return t;
201
203
  const r = e, s = new RegExp(`^\\s*(?:\\S+\\s*){1,${r}}`, "u"), o = t.match(s);
202
- return !o || z(t) === z(o[0]) ? t : o[0].trimEnd() + n;
204
+ return !o || N(t) === N(o[0]) ? t : o[0].trimEnd() + n;
203
205
  }
204
- function Mt(t, e, n, r = null) {
206
+ function Gt(t, e, n, r = null) {
205
207
  if (e === "")
206
208
  return t;
207
209
  const s = t.length;
@@ -216,7 +218,7 @@ function Mt(t, e, n, r = null) {
216
218
  const i = t.slice(0, o), f = c.length, l = t.slice(o + f);
217
219
  return i + e.slice(0, 1).repeat(f) + l;
218
220
  }
219
- function Ut(t, e) {
221
+ function Tt(t, e) {
220
222
  let n = "u", r = t;
221
223
  if (t.length >= 2 && t[0] === "/") {
222
224
  let s = -1;
@@ -245,7 +247,7 @@ function Ut(t, e) {
245
247
  return "";
246
248
  }
247
249
  }
248
- function Pt(t, e) {
250
+ function Bt(t, e) {
249
251
  e = String(e);
250
252
  const n = typeof t == "string" ? [t] : Array.from(t);
251
253
  for (const r of n) {
@@ -279,7 +281,7 @@ function Pt(t, e) {
279
281
  }
280
282
  return !1;
281
283
  }
282
- function It(t, e) {
284
+ function Ht(t, e) {
283
285
  let n = "u", r = t;
284
286
  if (t.length >= 2 && t[0] === "/") {
285
287
  let o = -1;
@@ -313,37 +315,37 @@ function It(t, e) {
313
315
  }
314
316
  return s;
315
317
  }
316
- function qt(t) {
317
- return x(t) ? t.map((e) => e.replace(/[^0-9]/g, "")) : t.replace(/[^0-9]/g, "");
318
+ function Jt(t) {
319
+ return S(t) ? t.map((e) => e.replace(/[^0-9]/g, "")) : t.replace(/[^0-9]/g, "");
318
320
  }
319
- function Gt(t, e, n = " ") {
321
+ function Kt(t, e, n = " ") {
320
322
  const r = t.length;
321
323
  if (e <= r || n === "")
322
324
  return t;
323
325
  const s = e - r, o = Math.floor(s / 2), c = s - o;
324
- return N(n, o) + t + N(n, c);
326
+ return z(n, o) + t + z(n, c);
325
327
  }
326
- function Tt(t, e, n = " ") {
328
+ function Zt(t, e, n = " ") {
327
329
  const r = t.length;
328
330
  if (e <= r || n === "")
329
331
  return t;
330
332
  const o = e - r;
331
- return N(n, o) + t;
333
+ return z(n, o) + t;
332
334
  }
333
- function Bt(t, e, n = " ") {
335
+ function jt(t, e, n = " ") {
334
336
  const r = t.length;
335
337
  if (e <= r || n === "")
336
338
  return t;
337
339
  const o = e - r;
338
- return t + N(n, o);
340
+ return t + z(n, o);
339
341
  }
340
- function N(t, e) {
342
+ function z(t, e) {
341
343
  if (e <= 0 || t.length === 0)
342
344
  return "";
343
345
  const n = Math.ceil(e / t.length);
344
346
  return t.repeat(n).slice(0, e);
345
347
  }
346
- function Ht(t = 32, e = !0, n = !0, r = !0, s = !1) {
348
+ function Dt(t = 32, e = !0, n = !0, r = !0, s = !1) {
347
349
  const l = [
348
350
  e ? [
349
351
  "a",
@@ -429,7 +431,7 @@ function Ht(t = 32, e = !0, n = !0, r = !0, s = !1) {
429
431
  ";"
430
432
  ] : null,
431
433
  s ? [" "] : null
432
- ].filter((u) => x(u));
434
+ ].filter((u) => S(u));
433
435
  if (l.length === 0 || t <= 0)
434
436
  return "";
435
437
  const p = [];
@@ -448,7 +450,7 @@ function Ht(t = 32, e = !0, n = !0, r = !0, s = !1) {
448
450
  }
449
451
  return p.join("");
450
452
  }
451
- function Jt(t, e, n = 0) {
453
+ function Qt(t, e, n = 0) {
452
454
  if (e === "")
453
455
  return !1;
454
456
  const r = Array.from(t), s = Array.from(e);
@@ -468,31 +470,31 @@ function Jt(t, e, n = 0) {
468
470
  }
469
471
  return !1;
470
472
  }
471
- function Y(t = 16) {
473
+ function tt(t = 16) {
472
474
  return (L ?? ((n) => D(n)))(t);
473
475
  }
474
- function v(t) {
476
+ function et(t) {
475
477
  L = t;
476
478
  }
477
- function Kt(t, e) {
479
+ function Vt(t, e) {
478
480
  let n = 0;
479
481
  const r = e ?? function(s) {
480
482
  const o = L;
481
483
  L = null;
482
- const c = Y(s);
484
+ const c = tt(s);
483
485
  return L = o, n++, c;
484
486
  };
485
- v((s) => n < t.length ? String(t[n++]) : r(s));
487
+ et((s) => n < t.length ? String(t[n++]) : r(s));
486
488
  }
487
- function Zt() {
489
+ function nt() {
488
490
  L = null;
489
491
  }
490
- function jt(t, e) {
492
+ function Xt(t, e) {
491
493
  return e <= 0 ? "" : t.repeat(e);
492
494
  }
493
- function Dt(t, e, n) {
495
+ function Yt(t, e, n) {
494
496
  let r;
495
- typeof e == "object" && !x(e) ? r = Object.values(e) : r = x(e) ? [...e] : Array.from(e);
497
+ typeof e == "object" && !S(e) ? r = Object.values(e) : r = S(e) ? [...e] : Array.from(e);
496
498
  const s = n.split(t);
497
499
  if (s.length === 1)
498
500
  return n;
@@ -503,7 +505,7 @@ function Dt(t, e, n) {
503
505
  }
504
506
  return String(o);
505
507
  }
506
- function Qt(t, e) {
508
+ function vt(t, e) {
507
509
  try {
508
510
  const n = String(t);
509
511
  if (n.length)
@@ -513,7 +515,7 @@ function Qt(t, e) {
513
515
  return e;
514
516
  }
515
517
  }
516
- function Vt(t, e, n, r = !0) {
518
+ function te(t, e, n, r = !0) {
517
519
  const s = (l) => typeof l == "string" ? [l] : Array.from(l), o = s(t), c = s(e), i = (l) => l.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), f = (l) => o.reduce((p, a, g) => {
518
520
  if (a === "") return p;
519
521
  const u = c[g] ?? "";
@@ -524,26 +526,26 @@ function Vt(t, e, n, r = !0) {
524
526
  }, l);
525
527
  return _(n) ? f(n) : Array.from(n).map(f);
526
528
  }
527
- function tt(t, e, n) {
529
+ function rt(t, e, n) {
528
530
  if (t = String(t), t === "")
529
531
  return n;
530
532
  const r = n.indexOf(t);
531
533
  return r !== -1 ? n.slice(0, r) + e + n.slice(r + t.length) : n;
532
534
  }
533
- function Xt(t, e, n) {
534
- return t = String(t), t === "" ? n : U(n, t) ? tt(t, e, n) : n;
535
+ function ee(t, e, n) {
536
+ return t = String(t), t === "" ? n : M(n, t) ? rt(t, e, n) : n;
535
537
  }
536
- function et(t, e, n) {
538
+ function st(t, e, n) {
537
539
  if (t = String(t), t === "")
538
540
  return n;
539
541
  const r = n.lastIndexOf(t);
540
542
  return r !== -1 ? n.slice(0, r) + e + n.slice(r + t.length) : n;
541
543
  }
542
- function Yt(t, e, n) {
543
- return t = String(t), t === "" ? n : M(n, t) ? et(t, e, n) : n;
544
+ function ne(t, e, n) {
545
+ return t = String(t), t === "" ? n : W(n, t) ? st(t, e, n) : n;
544
546
  }
545
- function vt(t, e, n, r = -1) {
546
- const s = (a) => x(a) ? a : [a], o = s(t);
547
+ function re(t, e, n, r = -1) {
548
+ const s = (a) => S(a) ? a : [a], o = s(t);
547
549
  function c(a) {
548
550
  try {
549
551
  if (a instanceof RegExp) {
@@ -630,9 +632,9 @@ function vt(t, e, n, r = -1) {
630
632
  }
631
633
  return g;
632
634
  };
633
- return x(n) ? n.map(p) : p(n);
635
+ return S(n) ? n.map(p) : p(n);
634
636
  }
635
- function nt(t) {
637
+ function ot(t) {
636
638
  let e = "", n = !1;
637
639
  for (let r = 0; r < t.length; r++) {
638
640
  const s = t[r];
@@ -640,7 +642,7 @@ function nt(t) {
640
642
  }
641
643
  return e;
642
644
  }
643
- function te(t, e, n = !0) {
645
+ function se(t, e, n = !0) {
644
646
  const r = typeof t == "string" ? [t] : Array.from(t), s = (c) => c.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), o = (c) => {
645
647
  let i = c;
646
648
  for (const f of r)
@@ -655,25 +657,25 @@ function te(t, e, n = !0) {
655
657
  };
656
658
  return typeof e == "string" ? o(e) : Array.from(e, (c) => o(String(c)));
657
659
  }
658
- function ee(t) {
660
+ function oe(t) {
659
661
  return Array.from(t).reverse().join("");
660
662
  }
661
- function ne(t, e) {
663
+ function ie(t, e) {
662
664
  const n = e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
663
665
  return e + t.replace(new RegExp(`^(?:${n})+`, "u"), "");
664
666
  }
665
- function re(t) {
667
+ function ce(t) {
666
668
  const e = String(t).trim();
667
669
  if (e === "")
668
670
  return "";
669
671
  let n = e.split(/\s+/u);
670
- return n.length > 1 ? n = n.map((s) => I(s)) : n = ot(n.join("_")).map((s) => I(s)), n.join("_").replace(/[-_ ]+/gu, "_").split("_").filter((s) => s.length > 0).join(" ");
672
+ return n.length > 1 ? n = n.map((s) => I(s)) : n = lt(n.join("_")).map((s) => I(s)), n.join("_").replace(/[-_ ]+/gu, "_").split("_").filter((s) => s.length > 0).join(" ");
671
673
  }
672
- function se(t, e = !1) {
674
+ function le(t, e = !1) {
673
675
  const r = t.split(/\s+/u).filter((s) => s.length > 0).map((s) => [...s][0]).join("");
674
676
  return e ? T(r) : r;
675
677
  }
676
- function oe(t) {
678
+ function fe(t) {
677
679
  if (t.trim() === "")
678
680
  return t;
679
681
  const e = /* @__PURE__ */ new Set([
@@ -729,17 +731,17 @@ function oe(t) {
729
731
  }
730
732
  return r.join(" ");
731
733
  }
732
- function rt(t, e = "_") {
734
+ function it(t, e = "_") {
733
735
  const r = `${t}|${e}`;
734
736
  if (R.has(r))
735
737
  return R.get(r);
736
738
  let s = t;
737
- return /^[a-z]+$/.test(t) || (s = it(t).replace(/\s+/gu, ""), s = s.replace(/(.)(?=[A-Z])/g, `$1${e}`), s = J(s)), R.set(r, s), s;
739
+ return /^[a-z]+$/.test(t) || (s = ft(t).replace(/\s+/gu, ""), s = s.replace(/(.)(?=[A-Z])/g, `$1${e}`), s = J(s)), R.set(r, s), s;
738
740
  }
739
- function ie(t) {
741
+ function ae(t) {
740
742
  return Q(t).replace(/[\s\u3164\u1160]+/gu, " ");
741
743
  }
742
- function U(t, e) {
744
+ function M(t, e) {
743
745
  if (t == null || e == null)
744
746
  return !1;
745
747
  let n;
@@ -754,8 +756,8 @@ function U(t, e) {
754
756
  }
755
757
  return !1;
756
758
  }
757
- function ce(t, e) {
758
- return !U(t, e);
759
+ function ue(t, e) {
760
+ return !M(t, e);
759
761
  }
760
762
  function K(t) {
761
763
  const e = t;
@@ -768,10 +770,10 @@ function K(t) {
768
770
  }, o = r.map(s).join("");
769
771
  return F.set(e, o), o;
770
772
  }
771
- function le(t) {
773
+ function pe(t) {
772
774
  return K(t);
773
775
  }
774
- function fe(t, e) {
776
+ function ge(t, e) {
775
777
  if (!t || Object.keys(t).length === 0)
776
778
  return e;
777
779
  const n = Object.keys(t).filter((o) => o !== "");
@@ -781,28 +783,28 @@ function fe(t, e) {
781
783
  const r = (o) => o.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), s = new RegExp(n.map(r).join("|"), "gu");
782
784
  return e.replace(s, (o) => t[o]);
783
785
  }
784
- function ae(t, e) {
785
- return e < 0 ? S(t, e) : S(t, 0, e);
786
+ function me(t, e) {
787
+ return e < 0 ? x(t, e) : x(t, 0, e);
786
788
  }
787
- function st(t) {
788
- return J(S(t, 0, 1)) + S(t, 1);
789
+ function ct(t) {
790
+ return J(x(t, 0, 1)) + x(t, 1);
789
791
  }
790
- function ue(t) {
791
- return T(S(t, 0, 1)) + S(t, 1);
792
+ function he(t) {
793
+ return T(x(t, 0, 1)) + x(t, 1);
792
794
  }
793
- function ot(t) {
795
+ function lt(t) {
794
796
  return t.split(new RegExp("(?=\\p{Lu})", "u")).filter(Boolean);
795
797
  }
796
- function it(t, e = ` \r
798
+ function ft(t, e = ` \r
797
799
  \f\v`) {
798
- const n = x(e) ? e.join("") : e, r = (i) => i.replace(/[-\\^$*+?.()|[\]{}]/g, "\\$&"), s = n.length ? r(n) : "", o = s.length ? `(?:\\s|[${s}])` : "\\s", c = new RegExp(`(^|${o})(\\p{Ll})`, "gu");
800
+ const n = S(e) ? e.join("") : e, r = (i) => i.replace(/[-\\^$*+?.()|[\]{}]/g, "\\$&"), s = n.length ? r(n) : "", o = s.length ? `(?:\\s|[${s}])` : "\\s", c = new RegExp(`(^|${o})(\\p{Ll})`, "gu");
799
801
  return t.replace(c, (i, f, l) => f + l.toUpperCase());
800
802
  }
801
- function pe(t, e = null) {
803
+ function de(t, e = null) {
802
804
  const n = e && e.length > 0 ? e.replace(/[-\\^$*+?.()|[\]{}]/g, "\\$&") : "", r = n.length > 0 ? new RegExp(`[\\p{L}\\p{N}${n}]+`, "gu") : /[\p{L}\p{N}]+/gu, s = t.match(r);
803
805
  return s ? s.length : 0;
804
806
  }
805
- function ge(t, e = 75, n = `
807
+ function ye(t, e = 75, n = `
806
808
  `, r = !1) {
807
809
  if (t.length === 0 || e < 1 || n === "")
808
810
  return t;
@@ -851,95 +853,99 @@ function ge(t, e = 75, n = `
851
853
  }
852
854
  return o.join(n);
853
855
  }
854
- function me() {
856
+ function we() {
855
857
  return R.size;
856
858
  }
857
- function he() {
859
+ function Se() {
858
860
  return C.size;
859
861
  }
860
- function de() {
862
+ function xe() {
861
863
  return F.size;
862
864
  }
863
- function ye() {
865
+ function $e() {
864
866
  R.clear(), C.clear(), F.clear();
865
867
  }
868
+ function ke() {
869
+ nt(), V(), X();
870
+ }
866
871
  export {
867
872
  B as after,
868
- gt as afterLast,
869
- oe as apa,
870
- V as before,
871
- X as beforeLast,
872
- mt as between,
873
- ht as betweenFirst,
874
- dt as camel,
875
- he as camelCacheSize,
876
- yt as charAt,
877
- xt as chopEnd,
878
- wt as chopStart,
873
+ wt as afterLast,
874
+ fe as apa,
875
+ Y as before,
876
+ v as beforeLast,
877
+ St as between,
878
+ xt as betweenFirst,
879
+ $t as camel,
880
+ Se as camelCacheSize,
881
+ kt as charAt,
882
+ bt as chopEnd,
883
+ At as chopStart,
879
884
  H as contains,
880
- $t as containsAll,
881
- Zt as createRandomStringsNormally,
882
- v as createRandomStringsUsing,
883
- Kt as createRandomStringsUsingSequence,
884
- At as deduplicate,
885
- kt as doesntContain,
886
- bt as doesntEndWith,
887
- ce as doesntStartWith,
888
- M as endsWith,
889
- St as excerpt,
890
- Et as finish,
891
- ye as flushCache,
892
- re as headline,
893
- se as initials,
894
- Ct as is,
895
- Ft as isAscii,
896
- zt as isJson,
897
- Pt as isMatch,
898
- Nt as isUrl,
899
- _t as kebab,
900
- st as lcfirst,
901
- z as length,
902
- Ot as limit,
885
+ Lt as containsAll,
886
+ nt as createRandomStringsNormally,
887
+ et as createRandomStringsUsing,
888
+ Vt as createRandomStringsUsingSequence,
889
+ Ct as deduplicate,
890
+ Rt as doesntContain,
891
+ Ft as doesntEndWith,
892
+ ue as doesntStartWith,
893
+ W as endsWith,
894
+ Et as excerpt,
895
+ Nt as finish,
896
+ $e as flushCache,
897
+ ce as headline,
898
+ le as initials,
899
+ Ot as is,
900
+ Ut as isAscii,
901
+ Wt as isJson,
902
+ Bt as isMatch,
903
+ Mt as isUrl,
904
+ Pt as kebab,
905
+ ct as lcfirst,
906
+ N as length,
907
+ It as limit,
903
908
  J as lower,
904
- N as makePad,
905
- Mt as mask,
906
- Ut as match,
907
- It as matchAll,
908
- qt as numbers,
909
- Gt as padBoth,
910
- Tt as padLeft,
911
- Bt as padRight,
912
- le as pascal,
913
- Ht as password,
914
- Jt as position,
915
- Y as random,
916
- te as remove,
917
- jt as repeat,
918
- Vt as replace,
919
- Dt as replaceArray,
920
- Yt as replaceEnd,
921
- tt as replaceFirst,
922
- et as replaceLast,
923
- vt as replaceMatches,
924
- Xt as replaceStart,
925
- ee as reverse,
926
- rt as snake,
927
- me as snakeCacheSize,
928
- ie as squish,
929
- ne as start,
930
- U as startsWith,
931
- nt as stripTags,
909
+ z as makePad,
910
+ Gt as mask,
911
+ Tt as match,
912
+ Ht as matchAll,
913
+ Jt as numbers,
914
+ Kt as padBoth,
915
+ Zt as padLeft,
916
+ jt as padRight,
917
+ pe as pascal,
918
+ Dt as password,
919
+ Qt as position,
920
+ tt as random,
921
+ se as remove,
922
+ Xt as repeat,
923
+ te as replace,
924
+ Yt as replaceArray,
925
+ ne as replaceEnd,
926
+ rt as replaceFirst,
927
+ st as replaceLast,
928
+ re as replaceMatches,
929
+ ee as replaceStart,
930
+ ke as resetFactoryState,
931
+ oe as reverse,
932
+ it as snake,
933
+ we as snakeCacheSize,
934
+ ae as squish,
935
+ ie as start,
936
+ M as startsWith,
937
+ ot as stripTags,
932
938
  K as studly,
933
- de as studlyCacheSize,
934
- fe as swap,
935
- ae as take,
936
- Qt as toStringOr,
937
- ue as ucfirst,
938
- ot as ucsplit,
939
- it as ucwords,
940
- Rt as unwrap,
941
- pe as wordCount,
942
- ge as wordWrap,
943
- Wt as words,
944
- Lt as wrap
939
+ xe as studlyCacheSize,
940
+ ge as swap,
941
+ me as take,
942
+ vt as toStringOr,
943
+ he as ucfirst,
944
+ lt as ucsplit,
945
+ ft as ucwords,
946
+ _t as unwrap,
947
+ de as wordCount,
948
+ ye as wordWrap,
949
+ qt as words,
950
+ zt as wrap
945
951
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tolki/str",
3
- "version": "1.0.10",
3
+ "version": "1.0.11",
4
4
  "description": "Utilities for working with strings similar to Laravel's Str & Stringable classes.",
5
5
  "author": "Abraham Arango <https://github.com/abetwothree>",
6
6
  "license": "MIT",