New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@snack-uikit/calendar

Package Overview
Dependencies
Maintainers
3
Versions
125
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@snack-uikit/calendar - npm Package Compare versions

Comparing version 0.7.4 to 0.7.5-preview-bd4095bc.0

4

dist/helperComponents/CalendarBase/CalendarBase.js

@@ -61,4 +61,4 @@ var __rest = (this && this.__rest) || function (s, e) {

const getTestId = useMemo(() => getTestIdBuilder(testId), [testId]);
const [, ctxLocale] = useLocale();
const locale = useMemo(() => getLocale({ localeProp, ctxLocale }), [ctxLocale, localeProp]);
const { lang: ctxLang } = useLocale();
const locale = useMemo(() => getLocale({ localeProp, ctxLang }), [ctxLang, localeProp]);
const firstNotDisableCell = useRef([0, 0]);

@@ -65,0 +65,0 @@ return (_jsx("div", Object.assign({}, extractSupportProps(rest), { className: cn(styles.calendar, className, CONTAINER_SIZE_MAP[size]), style: style, "data-size": size, "data-fit-to-container": fitToContainer || undefined, "data-test-id": testId, children: _jsxs(CalendarContext.Provider, { value: {

@@ -19,7 +19,7 @@ import { LocaleLang } from '@snack-uikit/locale';

export declare const getTestIdBuilder: (testId?: string) => (prefix: string) => string | undefined;
export declare const getLocale: ({ localeProp, ctxLocale }?: {
export declare const getLocale: ({ localeProp, ctxLang }?: {
localeProp?: Intl.Locale | undefined;
ctxLocale?: string | undefined;
ctxLang?: string | undefined;
}) => Intl.Locale;
export declare const getStartOfWeek: (locale: Intl.Locale) => import("weekstart").DayOfWeek;
export declare const isWeekend: (date: Date, viewMode: ViewMode) => boolean;

@@ -55,3 +55,3 @@ import { getWeekStartByLocale } from 'weekstart';

export const getTestIdBuilder = (testId) => (prefix) => (testId ? `${prefix}-${testId}` : undefined);
export const getLocale = ({ localeProp, ctxLocale } = {}) => { var _a; return localeProp || new Intl.Locale(ctxLocale ? ctxLocale.replace('_', '-') : (_a = navigator === null || navigator === void 0 ? void 0 : navigator.language) !== null && _a !== void 0 ? _a : 'ru-RU'); };
export const getLocale = ({ localeProp, ctxLang } = {}) => { var _a; return localeProp || new Intl.Locale(ctxLang ? ctxLang.replace('_', '-') : (_a = navigator === null || navigator === void 0 ? void 0 : navigator.language) !== null && _a !== void 0 ? _a : 'ru-RU'); };
export const getStartOfWeek = (locale) => getWeekStartByLocale(locale.language);

@@ -58,0 +58,0 @@ export const isWeekend = (date, viewMode) => {

@@ -7,3 +7,3 @@ {

"title": "Calendar",
"version": "0.7.4",
"version": "0.7.5-preview-bd4095bc.0",
"sideEffects": [

@@ -37,3 +37,2 @@ "*.css",

"@snack-uikit/icons": "0.20.1",
"@snack-uikit/locale": "0.3.0",
"@snack-uikit/utils": "3.2.0",

@@ -44,3 +43,6 @@ "classnames": "2.3.2",

},
"gitHead": "3a1dd5498600db7f34a4681a70254b81337ddeb4"
"peerDependencies": {
"@snack-uikit/locale": "*"
},
"gitHead": "53065276382788f1cae880a1303f6f5a47cdd750"
}

@@ -88,4 +88,4 @@ import { getWeekStartByLocale } from 'weekstart';

export const getLocale = ({ localeProp, ctxLocale }: { localeProp?: Intl.Locale; ctxLocale?: LocaleLang } = {}) =>
localeProp || new Intl.Locale(ctxLocale ? ctxLocale.replace('_', '-') : navigator?.language ?? 'ru-RU');
export const getLocale = ({ localeProp, ctxLang }: { localeProp?: Intl.Locale; ctxLang?: LocaleLang } = {}) =>
localeProp || new Intl.Locale(ctxLang ? ctxLang.replace('_', '-') : navigator?.language ?? 'ru-RU');

@@ -92,0 +92,0 @@ export const getStartOfWeek = (locale: Intl.Locale) => getWeekStartByLocale(locale.language);

Sorry, the diff of this file is not supported yet

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