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

@microsoft/atlas-js

Package Overview
Dependencies
Maintainers
4
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@microsoft/atlas-js - npm Package Compare versions

Comparing version 1.5.5 to 1.6.0

dist/behaviors/dismiss.d.ts

6

dist/elements/form-behavior.d.ts

@@ -75,3 +75,3 @@ export declare const defaultMessageStrings: {

}
export declare type NavigationSteps = 'follow' | 'hash-reload' | 'replace' | 'reload' | null;
export type NavigationSteps = 'follow' | 'hash-reload' | 'replace' | 'reload' | null;
export interface FormValidationError {

@@ -81,3 +81,3 @@ message: string;

}
export declare type FormValidationResult = {
export type FormValidationResult = {
valid: true;

@@ -88,3 +88,3 @@ } | {

};
declare type Validator = (input: HTMLValueElement, label: string) => string | null;
type Validator = (input: HTMLValueElement, label: string) => string | null;
export declare function getLabel(input: HTMLValueElement): string;

@@ -91,0 +91,0 @@ export declare function getField(input: HTMLValueElement): HTMLElement;

@@ -154,3 +154,3 @@ import { generateElementId, kebabToCamelCase } from '../utilities/util';

this.submitting = true;
setBusySubmitButton(form, this.submitting);
setBusySubmitButton(event, form, this.submitting);
const result = await this.validateForm(form);

@@ -229,3 +229,3 @@ if (!result.valid) {

this.submitting = isNavigating;
setBusySubmitButton(form, this.submitting);
setBusySubmitButton(event, form, this.submitting);
}

@@ -468,6 +468,12 @@ }

}
function setBusySubmitButton(form, isLoading) {
function setBusySubmitButton(event, form, isLoading) {
const submitter = event.submitter;
Array.from(form.elements).forEach(element => {
if (element instanceof HTMLButtonElement && element.type === 'submit') {
element.classList.toggle('is-loading', isLoading);
if (submitter && submitter === element) {
element.classList.toggle('is-loading', isLoading);
}
else {
element.disabled = isLoading;
}
}

@@ -474,0 +480,0 @@ });

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

export * from './behaviors/dismiss';
export * from './behaviors/popover';

@@ -2,0 +3,0 @@ export * from './behaviors/snap-scroll';

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

export * from './behaviors/dismiss';
export * from './behaviors/popover';

@@ -2,0 +3,0 @@ export * from './behaviors/snap-scroll';

{
"name": "@microsoft/atlas-js",
"version": "1.5.5",
"version": "1.6.0",
"public": true,

@@ -36,11 +36,11 @@ "description": "Scripts backing the Atlas Design System used by Microsoft's Developer Relations.",

"devDependencies": {
"eslint": "^8.24.0",
"eslint-plugin-import": "^2.26.0",
"eslint": "^8.38.0",
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-jasmine": "^4.1.3",
"eslint-plugin-jsdoc": "^39.3.6",
"eslint-plugin-security": "^1.5.0",
"rimraf": "^3.0.2",
"tslib": "^2.4.0",
"typescript": "^4.8.4"
"eslint-plugin-jsdoc": "^41.1.1",
"eslint-plugin-security": "^1.7.1",
"rimraf": "^5.0.0",
"tslib": "^2.5.0",
"typescript": "^5.0.4"
}
}

@@ -192,3 +192,3 @@ import { generateElementId, kebabToCamelCase } from '../utilities/util';

this.submitting = true;
setBusySubmitButton(form, this.submitting);
setBusySubmitButton(event, form, this.submitting);
const result = await this.validateForm(form);

@@ -279,3 +279,3 @@ if (!result.valid) {

this.submitting = isNavigating;
setBusySubmitButton(form, this.submitting);
setBusySubmitButton(event, form, this.submitting);
}

@@ -630,6 +630,11 @@ }

function setBusySubmitButton(form: HTMLFormElement, isLoading: boolean) {
function setBusySubmitButton(event: Event, form: HTMLFormElement, isLoading: boolean) {
const submitter = (event as SubmitEvent).submitter;
Array.from(form.elements).forEach(element => {
if (element instanceof HTMLButtonElement && element.type === 'submit') {
element.classList.toggle('is-loading', isLoading);
if (submitter && submitter === element) {
element.classList.toggle('is-loading', isLoading);
} else {
element.disabled = isLoading;
}
}

@@ -636,0 +641,0 @@ });

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

export * from './behaviors/dismiss';
export * from './behaviors/popover';

@@ -2,0 +3,0 @@ export * from './behaviors/snap-scroll';

Sorry, the diff of this file is not supported yet

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