@sandlada/vue-mdc
Version:

42 lines • 1.58 kB
TypeScript
/**
* @license
* Copyright 2019 Google LLC
* SPDX-License-Identifier: Apache-2.0
*
* @link
* https://github.com/material-components/material-web/blob/main/internal/controller/form-submitter.ts
*
* [Modified by Sandlada & Kai Orion]
*
* @license
* Copyright 2025 Sandlada & Kai Orion
* SPDX-License-Identifier: MIT
*/
export declare const FormSubmitterType: {
readonly Button: "button";
readonly Submit: "submit";
readonly Reset: "reset";
};
export type TFormSubmitterType = typeof FormSubmitterType[keyof typeof FormSubmitterType];
export interface FormSubmitterElement extends HTMLButtonElement {
/**
* A string indicating the form submission behavior of the element.
* Must be implemented by the custom element class.
*/
type: TFormSubmitterType;
/**
* The HTML name to use in form submission. When combined with a `value`, the
* submitting button's name/value will be added to the form data.
* Must be implemented by the custom element class, typically reflecting the 'name' attribute.
*/
name: string;
/**
* The value of the element. When combined with a `name`, the submitting
* element's name/value will be added to the form data.
* Must be implemented by the custom element class, typically reflecting the 'value' attribute.
*/
value: string;
}
export declare function setupFormSubmitter(elementInstance: FormSubmitterElement): void;
export declare function cleanupFormSubmitter(elementInstance: FormSubmitterElement): void;
//# sourceMappingURL=form-submitter.d.ts.map