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

@auronet/holidays

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@auronet/holidays - npm Package Compare versions

Comparing version 1.0.1 to 1.1.0

dist/HolidayProviders/AUProvider.d.ts

98

dist/Countries.js

@@ -218,2 +218,100 @@ export const Countries = [

},
{
name: 'Australia',
code: 'AU',
lang: 'EN',
states: [
{ name: 'Australian Capital Territory', code: 'ACT', regions: [] },
{ name: 'New South Wales', code: 'NSW', regions: [] },
{ name: 'Northern Territory', code: 'NT', regions: [] },
{ name: 'Queensland', code: 'QLD', regions: [] },
{ name: 'South Australia', code: 'SA', regions: [] },
{ name: 'Tasmania', code: 'TAS', regions: [] },
{ name: 'Victoria', code: 'VIC', regions: [] },
{ name: 'Western Australia', code: 'WA', regions: [] },
],
},
{
name: 'New Zealand',
code: 'NZ',
lang: 'EN',
states: [],
},
{
name: 'Canada',
code: 'CA',
lang: 'EN',
states: [
{ name: 'Alberta', code: 'AB', regions: [] },
{ name: 'British Columbia', code: 'BC', regions: [] },
{ name: 'Manitoba', code: 'MB', regions: [] },
{ name: 'New Brunswick', code: 'NB', regions: [] },
{ name: 'Newfoundland and Labrador', code: 'NL', regions: [] },
{ name: 'Nova Scotia', code: 'NS', regions: [] },
{ name: 'Ontario', code: 'ON', regions: [] },
{ name: 'Prince Edward Island', code: 'PE', regions: [] },
{ name: 'Québec', code: 'QC', regions: [] },
{ name: 'Saskatchewan', code: 'SK', regions: [] },
{ name: 'Northwest Territories', code: 'NT', regions: [] },
{ name: 'Nunavut', code: 'NU', regions: [] },
{ name: 'Yukon', code: 'YT', regions: [] },
],
},
{
name: 'United States of America',
code: 'US',
lang: 'EN',
states: [
{ name: 'Alabama', code: 'AL', regions: [] },
{ name: 'Alaska', code: 'AK', regions: [] },
{ name: 'Arizona', code: 'AZ', regions: [] },
{ name: 'Arkansas', code: 'AR', regions: [] },
{ name: 'Colorado', code: 'CO', regions: [] },
{ name: 'Connecticut', code: 'CT', regions: [] },
{ name: 'Delaware', code: 'DE', regions: [] },
{ name: 'Florida', code: 'FL', regions: [] },
{ name: 'Georgia', code: 'GA', regions: [] },
{ name: 'Hawaii', code: 'HI', regions: [] },
{ name: 'Idaho', code: 'ID', regions: [] },
{ name: 'Illinois', code: 'IL', regions: [] },
{ name: 'Indiana', code: 'IN', regions: [] },
{ name: 'Iowa', code: 'IA', regions: [] },
{ name: 'Kalifornien', code: 'CA', regions: [] },
{ name: 'Kansas', code: 'KS', regions: [] },
{ name: 'Kentucky', code: 'KY', regions: [] },
{ name: 'Louisiana', code: 'LA', regions: [] },
{ name: 'Maine', code: 'ME', regions: [] },
{ name: 'Maryland', code: 'MD', regions: [] },
{ name: 'Massachusetts', code: 'MA', regions: [] },
{ name: 'Michigan', code: 'MI', regions: [] },
{ name: 'Minnesota', code: 'MN', regions: [] },
{ name: 'Mississippi', code: 'MS', regions: [] },
{ name: 'Missouri', code: 'MO', regions: [] },
{ name: 'Montana', code: 'MT', regions: [] },
{ name: 'Nebraska', code: 'NE', regions: [] },
{ name: 'Nevada', code: 'NV', regions: [] },
{ name: 'New Hampshire', code: 'NH', regions: [] },
{ name: 'New Jersey', code: 'NJ', regions: [] },
{ name: 'New Mexico', code: 'NM', regions: [] },
{ name: 'New York', code: 'NY', regions: [] },
{ name: 'North Carolina', code: 'NC', regions: [] },
{ name: 'North Dakota', code: 'ND', regions: [] },
{ name: 'Ohio', code: 'OH', regions: [] },
{ name: 'Oklahoma', code: 'OK', regions: [] },
{ name: 'Oregon', code: 'OR', regions: [] },
{ name: 'Pennsylvania', code: 'PA', regions: [] },
{ name: 'Rhode Island', code: 'RI', regions: [] },
{ name: 'South Carolina', code: 'SC', regions: [] },
{ name: 'South Dakota', code: 'SD', regions: [] },
{ name: 'Tennessee', code: 'TN', regions: [] },
{ name: 'Texas', code: 'TX', regions: [] },
{ name: 'Utah', code: 'UT', regions: [] },
{ name: 'Vermont', code: 'VT', regions: [] },
{ name: 'Virginia', code: 'VA', regions: [] },
{ name: 'Washington', code: 'WA', regions: [] },
{ name: 'West Virginia', code: 'WV', regions: [] },
{ name: 'Wisconsin', code: 'WI', regions: [] },
{ name: 'Wyoming', code: 'WY', regions: [] },
],
},
];

4

dist/HolidayProviders/index.d.ts

@@ -21,1 +21,5 @@ export { DEProvider } from './DEProvider.js';

export { TRProvider } from './TRProvider.js';
export { AUProvider } from './AUProvider.js';
export { CAProvider } from './CAProvider.js';
export { NZProvider } from './NZProvider.js';
export { USProvider } from './USProvider.js';

@@ -21,1 +21,5 @@ export { DEProvider } from './DEProvider.js';

export { TRProvider } from './TRProvider.js';
export { AUProvider } from './AUProvider.js';
export { CAProvider } from './CAProvider.js';
export { NZProvider } from './NZProvider.js';
export { USProvider } from './USProvider.js';
import { DateTime } from 'luxon';
import { HolidayProvider } from './lib/HolidayProvider.js';
import { ATProvider, BEProvider, CHProvider, CZProvider, DEProvider, ESProvider, FRProvider, GRProvider, HRProvider, HUProvider, IEProvider, ITProvider, LTProvider, NLProvider, PLProvider, PTProvider, ROProvider, SKProvider, TRProvider, UKProvider, } from './HolidayProviders/index.js';
import { ATProvider, AUProvider, BEProvider, CAProvider, CHProvider, CZProvider, DEProvider, ESProvider, FRProvider, GRProvider, HRProvider, HUProvider, IEProvider, ITProvider, LTProvider, NLProvider, NZProvider, PLProvider, PTProvider, ROProvider, SKProvider, TRProvider, UKProvider, USProvider, } from './HolidayProviders/index.js';
export default class Holidays {

@@ -68,2 +68,14 @@ provider;

break;
case 'AU':
this.provider = new AUProvider();
break;
case 'CA':
this.provider = new CAProvider();
break;
case 'NZ':
this.provider = new NZProvider();
break;
case 'US':
this.provider = new USProvider();
break;
default:

@@ -70,0 +82,0 @@ this.provider = new HolidayProvider();

2

dist/lib/CountryCode.d.ts

@@ -1,1 +0,1 @@

export type CountryCode = 'DE' | 'GB' | 'NL' | 'BE' | 'FR' | 'IE' | 'ES' | 'PT' | 'CH' | 'IT' | 'AT' | 'HU' | 'RO' | 'CZ' | 'SK' | 'PL' | 'GR' | 'TR' | 'LT' | 'HR';
export type CountryCode = 'DE' | 'GB' | 'NL' | 'BE' | 'FR' | 'IE' | 'ES' | 'PT' | 'CH' | 'IT' | 'AT' | 'HU' | 'RO' | 'CZ' | 'SK' | 'PL' | 'GR' | 'TR' | 'LT' | 'HR' | 'AU' | 'NZ' | 'CA' | 'US';

@@ -0,1 +1,2 @@

import { DateTime } from 'luxon';
import { CountryCode } from './CountryCode.js';

@@ -5,2 +6,3 @@ export type HolidayType = 'public' | 'bank' | 'school' | 'observance';

date: string;
value: DateTime;
name: string;

@@ -13,3 +15,4 @@ englishName: string;

launchYear: number;
constructor(date: string, localName: string, englishName: string, countryCode: CountryCode, launchYear?: number, states?: string[], regions?: string[]);
constructor(date: string | DateTime, localName: string, englishName: string, countryCode: CountryCode, launchYear?: number, states?: string[], regions?: string[]);
SetCounties(states: string[]): PublicHoliday;
}

@@ -0,3 +1,5 @@

import { DateTime } from 'luxon';
export class PublicHoliday {
date;
value;
name;

@@ -11,3 +13,10 @@ englishName;

constructor(date, localName, englishName, countryCode, launchYear, states, regions) {
this.date = date;
if (date && date['isValid']) {
this.date = date.toISODate();
this.value = date;
}
else {
this.date = date;
this.value = DateTime.fromISO(date);
}
this.name = localName;

@@ -21,2 +30,6 @@ this.englishName = englishName;

}
SetCounties(states) {
this.states = states;
return this;
}
}
{
"name": "@auronet/holidays",
"version": "1.0.1",
"version": "1.1.0",
"scripts": {

@@ -11,3 +11,4 @@ "test": "yarn jest --detectOpenHandles",

"pub": "npm publish --access public",
"refreshVSToken": "vsts-npm-auth -config .npmrc -force"
"refreshVSToken": "vsts-npm-auth -config .npmrc -force",
"update": "npx npm-auto-packages-updater package.json"
},

@@ -22,18 +23,19 @@ "type": "module",

"devDependencies": {
"@types/node": "^14.0.13",
"@typescript-eslint/eslint-plugin": "^2.34.0",
"@typescript-eslint/parser": "^2.34.0",
"eslint": "^7.0.0",
"eslint-config-airbnb": "^18.1.0",
"eslint-config-prettier": "^6.11.0",
"@types/node": "^20.11.10",
"@typescript-eslint/eslint-plugin": "^6.20.0",
"@typescript-eslint/parser": "^6.20.0",
"eslint": "^8.56.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-config-prettier": "^9.1.0",
"eslint-config-typescript": "^3.0.0",
"eslint-formatter-pretty": "^3.0.1",
"eslint-plugin-import": "^2.7.0",
"eslint-plugin-jsx-a11y": "^6.0.2",
"eslint-plugin-prettier": "^3.0.0",
"eslint-plugin-react": "^7.20.0",
"eslint-formatter-pretty": "^6.0.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jsx-a11y": "^6.8.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.33.2",
"eslint-plugin-typescript": "^0.14.0",
"prettier": "^2.0.5",
"ts-node": "^8.10.1",
"typescript": "^5.2.2",
"npm-auto-packages-updater": "^1.0.1",
"prettier": "^3.2.4",
"ts-node": "^10.9.2",
"typescript": "^5.3.3",
"typescript-eslint-parser": "^22.0.0"

@@ -40,0 +42,0 @@ },

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