Skip to content

Commit

Permalink
feat(components): expand btn form participation
Browse files Browse the repository at this point in the history
Signed-off-by: Cory Rylan <cory@coryrylan.com>
  • Loading branch information
coryrylan committed Feb 9, 2023
1 parent c072e4b commit 825c16b
Show file tree
Hide file tree
Showing 20 changed files with 256 additions and 314 deletions.
2 changes: 1 addition & 1 deletion docs/src/_includes/utils/index.js
Expand Up @@ -47,9 +47,9 @@ export function getDescription(schema, elementName) {
export function getAPI(schema) {
return /* markdown */`${schema.elements.map(e => /* html */`
<h2 id="${e.tagName}-api" bp-text="subheading" bp-layout="m-t:md">${e.tagName}</h2>
${table('Events', e.events)}
${e.members? table('Properties', e.members.filter(m => m.privacy !== 'private').filter(m => m.privacy !== 'protected').filter(m => !m.name.startsWith('#')).filter(m => !m.name.startsWith('_'))) : ''}
${e.attributes ? table('Attributes', e.attributes.filter(m => !m.name.startsWith('_'))) : ''}
${table('Events', e.events)}
${table('CSS Properties', e.cssProperties)}
${e.slots ? table('Slots', e.slots.map(s => s.name ? s : ({ ...s, name: 'default' }))) : ''}`).join('\n')}`
}
Expand Down
10 changes: 9 additions & 1 deletion docs/src/_pages/components/button-expand.11ty.js
Expand Up @@ -3,7 +3,7 @@ import { getImport, getExample, getAPI } from '../../_includes/utils/index.js';

export const data = {
title: 'Button Expand',
aria: 'https://www.w3.org/WAI/ARIA/apg/patterns/button/',
aria: 'https://www.w3.org/WAI/ARIA/apg/patterns/switch/',
schema: schema.find(c => c.name === 'button-expand')
};

Expand All @@ -14,6 +14,14 @@ The expand button should have a clear and descriptive label that communicates it
${getExample(data.schema, 'example')}
${getExample(data.schema, 'disabled')}
${getExample(data.schema, 'readonly')}
${getExample(data.schema, 'form')}
The expand button is a form control type which means it can be part of [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData/FormData) in \`form\` elements.
${getImport(data.schema)}
## Accessibility
Expand Down
10 changes: 5 additions & 5 deletions docs/src/_pages/components/button-sort.11ty.js
Expand Up @@ -3,7 +3,7 @@ import { getImport, getExample, getAPI } from '../../_includes/utils/index.js';

export const data = {
title: 'Button Sort',
aria: 'https://www.w3.org/WAI/ARIA/apg/patterns/button/',
aria: 'https://www.w3.org/WAI/ARIA/apg/patterns/spinbutton/',
schema: schema.find(c => c.name === 'button-sort')
};

Expand All @@ -14,14 +14,14 @@ The sort button should have a clear and descriptive label that communicates the
${getExample(data.schema, 'example')}
${getExample(data.schema, 'form')}
The sort button is a form control type which means it can be part of [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData/FormData) in \`form\` elements.
${getExample(data.schema, 'disabled')}
${getExample(data.schema, 'readonly')}
${getExample(data.schema, 'form')}
The sort button is a form control type which means it can be part of [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData/FormData) in \`form\` elements.
${getImport(data.schema)}
## Accessibility
Expand Down
2 changes: 1 addition & 1 deletion docs/src/_pages/components/components.11tydata.js
Expand Up @@ -4,7 +4,7 @@ export default {
github: 'https://github.com/blueprintui',
package: {
name: '@blueprintui/components',
version: '1.0.0'
version: '1.5.1'
},
eleventyComputed: {
permalink: data => data.permalink ? data.permalink : `/docs/components/${data.page.fileSlug}.html`
Expand Down

0 comments on commit 825c16b

Please sign in to comment.