google-labs-jules[bot] d0c617fdd7 chore: migrate button component to components/button
Moves the `button` component to `components/button` and creates re-exports in the original `button` directory for backward compatibility.
This change also updates internal imports and includes copyright headers in the re-export files.
2025-12-09 19:25:30 +00:00

32 lines
807 B
TypeScript

/**
* @license
* Copyright 2023 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import './material-collection.js';
import './index.js';
import {
KnobTypesToKnobs,
MaterialCollection,
materialInitsToStoryInits,
setUpDemo,
} from './material-collection.js';
import {boolInput, Knob, textInput} from './index.js';
import {stories, StoryKnobs} from './stories.js';
const collection = new MaterialCollection<KnobTypesToKnobs<StoryKnobs>>(
'Button',
[
new Knob('label', {ui: textInput(), defaultValue: ''}),
new Knob('disabled', {ui: boolInput(), defaultValue: false}),
new Knob('softDisabled', {ui: boolInput(), defaultValue: false}),
],
);
collection.addStories(...materialInitsToStoryInits(stories));
setUpDemo(collection, {fonts: 'roboto', icons: 'material-symbols'});