-
Notifications
You must be signed in to change notification settings - Fork 209
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: expand templating to support #1822 by default
- Loading branch information
Showing
5 changed files
with
34 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export const argTypes = { | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
import { html, TemplateResult } from '@spectrum-web-components/base'; | ||
import { TemplateResult } from '@spectrum-web-components/base'; | ||
|
||
import '../{{> tagnamePartial }}.js'; | ||
import { Template } from './template.js'; | ||
import { argTypes } from './args.js'; | ||
|
||
export default { | ||
title: '{{displayName name}}', | ||
component: '{{> tagnamePartial}}', | ||
argTypes, | ||
}; | ||
|
||
export const Default = (): TemplateResult => { | ||
return html`<{{> tagnamePartial}}></{{> tagnamePartial}}>`; | ||
}; | ||
export const Default = (): TemplateResult => Template({}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import { html, TemplateResult } from '@spectrum-web-components/base'; | ||
|
||
import '@spectrum-web-components/{{ name }}/{{> tagnamePartial }}.js'; | ||
|
||
export interface Properties { | ||
} | ||
|
||
export const Template = (props: Properties): TemplateResult => { | ||
// Remove the console.log() when you're ready to consume `props` in the element below. | ||
// eslint-disable-next-line no-console | ||
console.log('template properties', props); | ||
return html`<{{> tagnamePartial}}></{{> tagnamePartial}}>`; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters