Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More →
Socket
Sign inDemoInstall
Socket

react-timezone-select

Package Overview
Dependencies
Maintainers
1
Versions
101
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-timezone-select - npm Package Compare versions

Comparing version 0.9.15 to 0.10.1

dist/index.d.ts

385

dist/index.js

@@ -1,227 +0,162 @@

"use strict";
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = exports.i18nTimezones = void 0;
var _react = _interopRequireWildcard(require("react"));
var _reactSelect = _interopRequireDefault(require("react-select"));
var _spacetime = _interopRequireDefault(require("spacetime"));
var _spacetimeInformal = require("spacetime-informal");
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function _getRequireWildcardCache() { return cache; }; return cache; }
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
var i18nTimezones = {
'Pacific/Midway': 'Midway Island, Samoa',
'Pacific/Honolulu': 'Hawaii',
'America/Juneau': 'Alaska',
'America/Boise': 'Mountain Time',
'America/Dawson': 'Dawson, Yukon',
'America/Chihuahua': 'Chihuahua, La Paz, Mazatlan',
'America/Phoenix': 'Arizona',
'America/Chicago': 'Central Time',
'America/Regina': 'Saskatchewan',
'America/Mexico_City': 'Guadalajara, Mexico City, Monterrey',
'America/Belize': 'Central America',
'America/Detroit': 'Eastern Time',
'America/Bogota': 'Bogota, Lima, Quito',
'America/Caracas': 'Caracas, La Paz',
'America/Santiago': 'Santiago',
'America/St_Johns': 'Newfoundland and Labrador',
'America/Sao_Paulo': 'Brasilia',
'America/Tijuana': 'Tijuana, Pacific Time',
'America/Argentina/Buenos_Aires': 'Buenos Aires, Georgetown',
'America/Godthab': 'Greenland',
'Atlantic/Azores': 'Azores',
'Atlantic/Cape_Verde': 'Cape Verde Islands',
GMT: 'Dublin, Edinburgh, Lisbon, London',
'Africa/Casablanca': 'Casablanca, Monrovia',
'Atlantic/Canary': 'Canary Islands',
'Europe/Belgrade': 'Belgrade, Bratislava, Budapest, Ljubljana, Prague',
'Europe/Sarajevo': 'Sarajevo, Skopje, Warsaw, Zagreb',
'Europe/Brussels': 'Brussels, Copenhagen, Madrid, Paris',
'Europe/Amsterdam': 'Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna',
'Africa/Algiers': 'West Central Africa',
'Europe/Bucharest': 'Bucharest',
'Africa/Cairo': 'Cairo',
'Europe/Helsinki': 'Helsinki, Kiev, Riga, Sofia, Tallinn, Vilnius',
'Europe/Athens': 'Athens, Istanbul, Minsk',
'Asia/Jerusalem': 'Jerusalem',
'Africa/Harare': 'Harare, Pretoria',
'Europe/Moscow': 'Moscow, St. Petersburg, Volgograd',
'Asia/Kuwait': 'Kuwait, Riyadh',
'Africa/Nairobi': 'Nairobi',
'Asia/Baghdad': 'Baghdad',
'Asia/Tehran': 'Tehran',
'Asia/Dubai': 'Abu Dhabi, Muscat',
'Asia/Baku': 'Baku, Tbilisi, Yerevan',
'Asia/Kabul': 'Kabul',
'Asia/Yekaterinburg': 'Ekaterinburg',
'Asia/Karachi': 'Islamabad, Karachi, Tashkent',
'Asia/Kolkata': 'Chennai, Kolkata, Mumbai, New Delhi',
'Asia/Kathmandu': 'Kathmandu',
'Asia/Dhaka': 'Astana, Dhaka',
'Asia/Colombo': 'Sri Jayawardenepura',
'Asia/Almaty': 'Almaty, Novosibirsk',
'Asia/Rangoon': 'Yangon Rangoon',
'Asia/Bangkok': 'Bangkok, Hanoi, Jakarta',
'Asia/Krasnoyarsk': 'Krasnoyarsk',
'Asia/Shanghai': 'Beijing, Chongqing, Hong Kong SAR, Urumqi',
'Asia/Kuala_Lumpur': 'Kuala Lumpur, Singapore',
'Asia/Taipei': 'Taipei',
'Australia/Perth': 'Perth',
'Asia/Irkutsk': 'Irkutsk, Ulaanbaatar',
'Asia/Seoul': 'Seoul',
'Asia/Tokyo': 'Osaka, Sapporo, Tokyo',
'Asia/Yakutsk': 'Yakutsk',
'Australia/Darwin': 'Darwin',
'Australia/Adelaide': 'Adelaide',
'Australia/Sydney': 'Canberra, Melbourne, Sydney',
'Australia/Brisbane': 'Brisbane',
'Australia/Hobart': 'Hobart',
'Asia/Vladivostok': 'Vladivostok',
'Pacific/Guam': 'Guam, Port Moresby',
'Asia/Magadan': 'Magadan, Solomon Islands, New Caledonia',
'Asia/Kamchatka': 'Kamchatka, Marshall Islands',
'Pacific/Fiji': 'Fiji Islands',
'Pacific/Auckland': 'Auckland, Wellington',
'Pacific/Tongatapu': "Nuku'alofa"
import * as React from 'react';
import Select from 'react-select';
import spacetime from 'spacetime';
import { display } from 'spacetime-informal';
export const i18nTimezones = {
'Pacific/Midway': 'Midway Island, Samoa',
'Pacific/Honolulu': 'Hawaii',
'America/Juneau': 'Alaska',
'America/Boise': 'Mountain Time',
'America/Dawson': 'Dawson, Yukon',
'America/Chihuahua': 'Chihuahua, La Paz, Mazatlan',
'America/Phoenix': 'Arizona',
'America/Chicago': 'Central Time',
'America/Regina': 'Saskatchewan',
'America/Mexico_City': 'Guadalajara, Mexico City, Monterrey',
'America/Belize': 'Central America',
'America/Detroit': 'Eastern Time',
'America/Bogota': 'Bogota, Lima, Quito',
'America/Caracas': 'Caracas, La Paz',
'America/Santiago': 'Santiago',
'America/St_Johns': 'Newfoundland and Labrador',
'America/Sao_Paulo': 'Brasilia',
'America/Tijuana': 'Tijuana, Pacific Time',
'America/Argentina/Buenos_Aires': 'Buenos Aires, Georgetown',
'America/Godthab': 'Greenland',
'Atlantic/Azores': 'Azores',
'Atlantic/Cape_Verde': 'Cape Verde Islands',
GMT: 'Dublin, Edinburgh, Lisbon, London',
'Africa/Casablanca': 'Casablanca, Monrovia',
'Atlantic/Canary': 'Canary Islands',
'Europe/Belgrade': 'Belgrade, Bratislava, Budapest, Ljubljana, Prague',
'Europe/Sarajevo': 'Sarajevo, Skopje, Warsaw, Zagreb',
'Europe/Brussels': 'Brussels, Copenhagen, Madrid, Paris',
'Europe/Amsterdam': 'Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna',
'Africa/Algiers': 'West Central Africa',
'Europe/Bucharest': 'Bucharest',
'Africa/Cairo': 'Cairo',
'Europe/Helsinki': 'Helsinki, Kiev, Riga, Sofia, Tallinn, Vilnius',
'Europe/Athens': 'Athens, Istanbul, Minsk',
'Asia/Jerusalem': 'Jerusalem',
'Africa/Harare': 'Harare, Pretoria',
'Europe/Moscow': 'Moscow, St. Petersburg, Volgograd',
'Asia/Kuwait': 'Kuwait, Riyadh',
'Africa/Nairobi': 'Nairobi',
'Asia/Baghdad': 'Baghdad',
'Asia/Tehran': 'Tehran',
'Asia/Dubai': 'Abu Dhabi, Muscat',
'Asia/Baku': 'Baku, Tbilisi, Yerevan',
'Asia/Kabul': 'Kabul',
'Asia/Yekaterinburg': 'Ekaterinburg',
'Asia/Karachi': 'Islamabad, Karachi, Tashkent',
'Asia/Kolkata': 'Chennai, Kolkata, Mumbai, New Delhi',
'Asia/Kathmandu': 'Kathmandu',
'Asia/Dhaka': 'Astana, Dhaka',
'Asia/Colombo': 'Sri Jayawardenepura',
'Asia/Almaty': 'Almaty, Novosibirsk',
'Asia/Rangoon': 'Yangon Rangoon',
'Asia/Bangkok': 'Bangkok, Hanoi, Jakarta',
'Asia/Krasnoyarsk': 'Krasnoyarsk',
'Asia/Shanghai': 'Beijing, Chongqing, Hong Kong SAR, Urumqi',
'Asia/Kuala_Lumpur': 'Kuala Lumpur, Singapore',
'Asia/Taipei': 'Taipei',
'Australia/Perth': 'Perth',
'Asia/Irkutsk': 'Irkutsk, Ulaanbaatar',
'Asia/Seoul': 'Seoul',
'Asia/Tokyo': 'Osaka, Sapporo, Tokyo',
'Asia/Yakutsk': 'Yakutsk',
'Australia/Darwin': 'Darwin',
'Australia/Adelaide': 'Adelaide',
'Australia/Sydney': 'Canberra, Melbourne, Sydney',
'Australia/Brisbane': 'Brisbane',
'Australia/Hobart': 'Hobart',
'Asia/Vladivostok': 'Vladivostok',
'Pacific/Guam': 'Guam, Port Moresby',
'Asia/Magadan': 'Magadan, Solomon Islands, New Caledonia',
'Asia/Kamchatka': 'Kamchatka, Marshall Islands',
'Pacific/Fiji': 'Fiji Islands',
'Pacific/Auckland': 'Auckland, Wellington',
'Pacific/Tongatapu': "Nuku'alofa",
};
exports.i18nTimezones = i18nTimezones;
var TimezoneSelect = function TimezoneSelect(_ref) {
var value = _ref.value,
onBlur = _ref.onBlur,
onChange = _ref.onChange,
_ref$labelStyle = _ref.labelStyle,
labelStyle = _ref$labelStyle === void 0 ? 'original' : _ref$labelStyle,
timezones = _ref.timezones,
props = _objectWithoutProperties(_ref, ["value", "onBlur", "onChange", "labelStyle", "timezones"]);
var _useState = (0, _react.useState)({}),
_useState2 = _slicedToArray(_useState, 2),
selectedTimezone = _useState2[0],
setSelectedTimezone = _useState2[1];
timezones = timezones || i18nTimezones;
var getOptions = (0, _react.useMemo)(function () {
var options = [];
Object.entries(timezones).reduce(function (obj, entry) {
var a = _spacetime["default"].now()["goto"](entry[0]);
var tz = a.timezone();
var tzDisplay = (0, _spacetimeInformal.display)(entry[0]);
var abbrev = entry[0];
var altName = entry[0];
if (tzDisplay && tzDisplay.daylight && tzDisplay.standard) {
abbrev = a.isDST() ? tzDisplay.daylight.abbrev : tzDisplay.standard.abbrev;
altName = a.isDST() ? tzDisplay.daylight.name : tzDisplay.standard.name;
}
obj.push({
name: entry[0],
label: entry[1],
offset: tz.current.offset,
abbrev: abbrev,
altName: altName
});
return obj;
}).sort(function (a, b) {
return a.offset - b.offset;
}).map(function (tz) {
if (tz.offset === undefined) return false;
var label = '';
var min = tz.offset * 60;
var hr = "".concat(min / 60 ^ 0, ":") + (min % 60 === 0 ? '00' : Math.abs(min % 60));
var prefix = "(GMT".concat(hr.includes('-') ? hr : "+".concat(hr), ") ").concat(tz.label);
switch (labelStyle) {
case 'original':
label = prefix;
break;
case 'altName':
label = "".concat(prefix, " ").concat(!tz.altName.includes('/') ? "(".concat(tz.altName, ")") : '');
break;
case 'abbrev':
label = "".concat(prefix, " \n ").concat(tz.abbrev.length < 5 ? "(".concat(tz.abbrev, ")") : '');
break;
default:
label = "".concat(prefix);
}
options.push({
value: tz.name,
label: label,
abbrev: tz.abbrev,
altName: tz.altName
});
});
return options;
}, [labelStyle]);
var handleChange = function handleChange(tz) {
setSelectedTimezone(tz);
onChange && onChange(tz);
};
var constructTz = function constructTz(value) {
var returnTz;
if (value.value && value.label) {
returnTz = value;
} else if (value.value && !value.label) {
returnTz = getOptions.find(function (tz) {
return tz.value === value.value;
});
} else if (typeof value === 'string' && !selectedTimezone.label) {
returnTz = getOptions.find(function (tz) {
return tz.value === value;
});
}
return returnTz;
};
return /*#__PURE__*/_react["default"].createElement(_reactSelect["default"], _extends({
value: constructTz(value),
onChange: handleChange,
options: getOptions,
onBlur: onBlur
}, props));
const TimezoneSelect = ({ value, onBlur, onChange, labelStyle = 'original', timezones, ...props }) => {
timezones = timezones || i18nTimezones;
const getOptions = React.useMemo(() => {
const options = [];
console.log(Object.entries(timezones));
Object.entries(timezones)
.reduce((obj, entry) => {
const a = spacetime.now().goto(entry[0]);
const tz = a.timezone();
const tzDisplay = display(entry[0]);
let abbrev = entry[0];
let altName = entry[0];
if (tzDisplay && tzDisplay.daylight && tzDisplay.standard) {
abbrev = a.isDST()
? tzDisplay.daylight.abbrev
: tzDisplay.standard.abbrev;
altName = a.isDST()
? tzDisplay.daylight.name
: tzDisplay.standard.name;
}
obj.push({
name: entry[0],
label: entry[1],
offset: tz.current.offset,
abbrev: abbrev,
altName: altName,
});
return obj;
}, {})
.sort((a, b) => {
return a.offset - b.offset;
})
.map((tz) => {
if (tz.offset === undefined)
return false;
let label = '';
const min = tz.offset * 60;
const hr = `${(min / 60) ^ 0}:` + (min % 60 === 0 ? '00' : Math.abs(min % 60));
const prefix = `(GMT${hr.includes('-') ? hr : `+${hr}`}) ${tz.label}`;
switch (labelStyle) {
case 'original':
label = prefix;
break;
case 'altName':
label = `${prefix} ${!tz.altName.includes('/') ? `(${tz.altName})` : ''}`;
break;
case 'abbrev':
label = `${prefix}
${tz.abbrev.length < 5 ? `(${tz.abbrev})` : ''}`;
break;
default:
label = `${prefix}`;
}
options.push({
value: tz.name,
label: label,
abbrev: tz.abbrev,
altName: tz.altName,
});
});
return options;
}, [labelStyle, timezones]);
const handleChange = (tz) => {
onChange && onChange(tz);
};
const normalizeTz = (value) => {
let returnTz;
if (typeof value === 'string') {
returnTz = getOptions.find(tz => tz.value === value);
}
else if (value.value && !value.label) {
returnTz = getOptions.find(tz => tz.value === value.value);
}
else {
returnTz = value;
}
return returnTz;
};
return (React.createElement(Select, Object.assign({ value: normalizeTz(value), onChange: handleChange, options: getOptions, onBlur: onBlur }, props)));
};
var _default = TimezoneSelect;
exports["default"]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ekRpc3BsYXkuZGF5bGlnaHQgJiYgdHpEaXNwbGF5LnN0YW5kYXJkKSB7XG4gICAgICAgICAgYWJicmV2ID0gYS5pc0RTVCgpXG4gICAgICAgICAgICA/IHR6RGlzcGxheS5kYXlsaWdodC5hYmJyZXZcbiAgICAgICAgICAgIDogdHpEaXNwbGF5LnN0YW5kYXJkLmFiYnJldlxuICAgICAgICAgIGFsdE5hbWUgPSBhLmlzRFNUKClcbiAgICAgICAgICAgID8gdHpEaXNwbGF5LmRheWxpZ2h0Lm5hbWVcbiAgICAgICAgICAgIDogdHpEaXNwbGF5LnN0YW5kYXJkLm5hbWVcbiAgICAgICAgfVxuICAgICAgICBvYmoucHVzaCh7XG4gICAgICAgICAgbmFtZTogZW50cnlbMF0sXG4gICAgICAgICAgbGFiZWw6IGVudHJ5WzFdLFxuICAgICAgICAgIG9mZnNldDogdHouY3VycmVudC5vZmZzZXQsXG4gICAgICAgICAgYWJicmV2OiBhYmJyZXYsXG4gICAgICAgICAgYWx0TmFtZTogYWx0TmFtZSxcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuIG9ialxuICAgICAgfSlcbiAgICAgIC5zb3J0KChhLCBiKSA9PiB7XG4gICAgICAgIHJldHVybiBhLm9mZnNldCAtIGIub2Zmc2V0XG4gICAgICB9KVxuICAgICAgLm1hcCh0eiA9PiB7XG4gICAgICAgIGlmICh0ei5vZmZzZXQgPT09IHVuZGVmaW5lZCkgcmV0dXJuIGZhbHNlXG4gICAgICAgIGxldCBsYWJlbCA9ICcnXG4gICAgICAgIGNvbnN0IG1pbiA9IHR6Lm9mZnNldCAqIDYwXG4gICAgICAgIGNvbnN0IGhyID1cbiAgICAgICAgICBgJHsobWluIC8gNjApIF4gMH06YCArIChtaW4gJSA2MCA9PT0gMCA/ICcwMCcgOiBNYXRoLmFicyhtaW4gJSA2MCkpXG4gICAgICAgIGNvbnN0IHByZWZpeCA9IGAoR01UJHtoci5pbmNsdWRlcygnLScpID8gaHIgOiBgKyR7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VyblR6XG4gICAgaWYgKHZhbHVlLnZhbHVlICYmIHZhbHVlLmxhYmVsKSB7XG4gICAgICByZXR1cm5UeiA9IHZhbHVlXG4gICAgfSBlbHNlIGlmICh2YWx1ZS52YWx1ZSAmJiAhdmFsdWUubGFiZWwpIHtcbiAgICAgIHJldHVyblR6ID0gZ2V0T3B0aW9ucy5maW5kKHR6ID0+IHR6LnZhbHVlID09PSB2YWx1ZS52YWx1ZSlcbiAgICB9IGVsc2UgaWYgKHR5cGVvZiB2YWx1ZSA9PT0gJ3N0cmluZycgJiYgIXNlbGVjdGVkVGltZXpvbmUubGFiZWwpIHtcbiAgICAgIHJldHVyblR6ID0gZ2V0T3B0aW9ucy5maW5kKHR6ID0+IHR6LnZhbHVlID09PSB2YWx1ZSlcbiAgICB9XG4gICAgcmV0dXJuIHJldHVyblR6XG4gIH1cblxuICByZXR1cm4gKFxuICAgIDxTZWxlY3RcbiAgICAgIHZhbHVlPXtjb25zdHJ1Y3RUeih2YWx1ZSl9XG4gICAgICBvbkNoYW5nZT17aGFuZGxlQ2hhbmdlfVxuICAgICAgb3B0aW9ucz17Z2V0T3B0aW9uc31cbiAgICAgIG9uQmx1cj17b25CbHVyfVxuICAgICAgey4uLnByb3BzfVxuICAgIC8+XG4gIClcbn1cblxuZXhwb3J0IGRlZmF1bHQgVGltZXpvbmVTZWxlY3RcbiJdfQ==
export default TimezoneSelect;
//# sourceMappingURL=index.js.map
{
"name": "react-timezone-select",
"version": "0.9.15",
"version": "0.10.1",
"description": "Usable, dynamic React Timezone Select",

@@ -8,7 +8,5 @@ "main": "dist/index.js",

"start": "webpack serve --mode development",
"transpile": "babel src -d dist -s inline --copy-files",
"prepublishOnly": "npm run transpile",
"build": "webpack --mode production",
"deploy": "gh-pages -d examples/dist",
"postpublish": "npm run build && npm run deploy"
"prepublish": "tsc",
"build": "tsc --project ./tsconfig.json",
"deploy": "gh-pages -d example/dist"
},

@@ -24,2 +22,3 @@ "author": "Nico Domino <yo@ndo.dev>",

},
"license": "MIT",
"keywords": [

@@ -34,3 +33,3 @@ "react",

],
"license": "MIT",
"types": "./dist/index.d.ts",
"module": "./dist/index.js",

@@ -45,20 +44,22 @@ "exports": {

"dependencies": {
"react-select": "^3.2.0",
"spacetime": "^6.12.2",
"react-select": "^4.0.2",
"spacetime": "^6.12.3",
"spacetime-informal": "^0.5.0"
},
"devDependencies": {
"@babel/cli": "^7.12.10",
"@babel/core": "^7.12.10",
"@babel/plugin-proposal-class-properties": "^7.12.1",
"@babel/preset-env": "^7.12.11",
"@babel/preset-react": "^7.12.10",
"babel-loader": "^8.2.2",
"@types/react": "^17.0.1",
"@types/react-dom": "^17.0.0",
"@types/react-select": "^4.0.13",
"css-loader": "^5.0.1",
"gh-pages": "^3.1.0",
"html-webpack-plugin": "^4.5.1",
"html-webpack-plugin": "^5.0.0",
"prettier": "^2.2.1",
"react": "^17.0.1",
"react-dom": "^17.0.1",
"source-map-loader": "^2.0.0",
"style-loader": "^2.0.0",
"webpack": "^5.16.0",
"webpack-cli": "^4.4.0",
"ts-loader": "^8.0.15",
"typescript": "^4.1.3",
"webpack": "^5.21.1",
"webpack-cli": "^4.5.0",
"webpack-dev-server": "^3.11.2"

@@ -65,0 +66,0 @@ },

@@ -22,3 +22,3 @@ # 🌐⌚ react-timezone-select

There is also a [Codesandbox](https://codesandbox.io/s/react-timezone-select-usage-z37hf) usage example for adjusting the timezone of a selected `spacetime` object, like how one might use this in a real app.
There is another Demo available on [Codesandbox](https://codesandbox.io/s/react-timezone-select-usage-z37hf) showing how to adjust the timezone of a selected `spacetime` object, like how one might use this in a real app.

@@ -28,3 +28,3 @@ ## 🏗ī¸ Installing

```bash
npm install --save-prod react-timezone-select
npm install react-timezone-select
```

@@ -64,10 +64,2 @@

<br />
<span style={{ marginLeft: '20px', fontWeight: '500' }}>
altName: '{selectedTimezone.altName}'
</span>
<br />
<span style={{ marginLeft: '20px', fontWeight: '500' }}>
abbrev: '{selectedTimezone.abbrev}'
</span>
<br />
{'}'}

@@ -85,2 +77,4 @@ </div>

> Update **v0.10.1+** we're now built with Typescript!
- `value` - `{ value: string, label: string, altName: string, abbrev: string }`

@@ -118,3 +112,3 @@ - `onBlur` - `() => void`

timezones={{
...i18nTimezones
...i18nTimezones,
'America/Lima': 'Pittsburgh',

@@ -121,0 +115,0 @@ 'Europe/Berlin': 'Frankfurt',

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡ī¸ by Socket Inc