react-timezone-select 3.2.1 → 3.2.3
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/index.js +3 -2
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
"use client"
|
|
2
|
+
|
|
1
3
|
var __defProp = Object.defineProperty;
|
|
2
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
@@ -119,7 +121,6 @@ var timezone_list_default = allTimezones;
|
|
|
119
121
|
|
|
120
122
|
// src/index.tsx
|
|
121
123
|
import { jsx } from "react/jsx-runtime";
|
|
122
|
-
"use client";
|
|
123
124
|
function useTimezoneSelect({
|
|
124
125
|
timezones = timezone_list_default,
|
|
125
126
|
labelStyle = "original",
|
|
@@ -184,7 +185,7 @@ function useTimezoneSelect({
|
|
|
184
185
|
if (tz.label.toLowerCase().indexOf(currentTime.tz.substring(currentTime.tz.indexOf("/") + 1)) !== -1) {
|
|
185
186
|
score += 4;
|
|
186
187
|
}
|
|
187
|
-
if (tz.value.toLowerCase().indexOf(currentTime.tz.substring(0, currentTime.tz.indexOf("/")))) {
|
|
188
|
+
if (tz.value.toLowerCase().indexOf(currentTime.tz.substring(0, currentTime.tz.indexOf("/"))) !== -1) {
|
|
188
189
|
score += 2;
|
|
189
190
|
}
|
|
190
191
|
score += 1;
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-timezone-select",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.3",
|
|
4
4
|
"description": "Usable, dynamic React Timezone Select",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"dev": "concurrently \"tsup src/index.tsx --format esm --watch\" \"cd example && pnpm dev\"",
|
|
7
7
|
"prepublishOnly": "pnpm run build",
|
|
8
8
|
"postpublish": "pnpm run build:example && npm run deploy",
|
|
9
|
-
"build": "tsup src/index.tsx --format esm --clean --dts",
|
|
9
|
+
"build": "tsup src/index.tsx --format esm --clean --dts && sed -i '1i \"use client\"\\n' dist/index.js",
|
|
10
10
|
"build:example": "cd example && pnpm run build",
|
|
11
11
|
"deploy": "gh-pages -d example/dist",
|
|
12
12
|
"pretest": "pnpm run build",
|