Skip to content

Commit

Permalink
feat: close shadow roots of all web components (#15382)
Browse files Browse the repository at this point in the history
* close shadow roots of all web components

* Change files

Co-authored-by: nicholasrice <nicholasrice@users.noreply.github.com>
  • Loading branch information
nicholasrice and nicholasrice authored Oct 6, 2020
1 parent ad2fdb0 commit d0d5148
Show file tree
Hide file tree
Showing 27 changed files with 80 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"type": "minor",
"comment": "close shadow roots of all web components",
"packageName": "@fluentui/web-components",
"email": "nicholasrice@users.noreply.github.com",
"dependentChangeType": "patch",
"date": "2020-10-06T16:07:15.935Z"
}
3 changes: 3 additions & 0 deletions packages/web-components/src/accordion/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ export * from './accordion-item/index';
name: 'fluent-accordion',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentAccordion extends Accordion {}

Expand Down
1 change: 1 addition & 0 deletions packages/web-components/src/anchor/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export type AnchorAppearance = ButtonAppearance | 'hypertext';
styles,
shadowOptions: {
delegatesFocus: true,
mode: 'closed',
},
})
export class FluentAnchor extends Anchor {
Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/badge/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ export type BadgeAppearance = 'accent' | 'lightweight' | 'neutral' | string;
name: 'fluent-badge',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentBadge extends Badge {
@attr({ mode: 'fromView' })
Expand Down
1 change: 1 addition & 0 deletions packages/web-components/src/button/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export type ButtonAppearance = 'accent' | 'lightweight' | 'neutral' | 'outline'
styles,
shadowOptions: {
delegatesFocus: true,
mode: 'closed',
},
})
export class FluentButton extends Button {
Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/card/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ import { CardStyles as styles } from './card.styles';
name: 'fluent-card',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentCard extends FluentDesignSystemProvider
implements Pick<DesignSystem, 'backgroundColor' | 'neutralPalette'> {
Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/checkbox/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { CheckboxStyles as styles } from './checkbox.styles';
name: 'fluent-checkbox',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentCheckbox extends Checkbox {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/design-system-provider/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ const backgroundStyles = css`
name: 'fluent-design-system-provider',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentDesignSystemProvider extends DesignSystemProvider
implements
Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/dialog/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { DialogStyles as styles } from './dialog.styles';
name: 'fluent-dialog',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentDialog extends Dialog {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/divider/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { DividerStyles as styles } from './divider.styles';
name: 'fluent-divider',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentDivider extends Divider {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/flipper/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { FlipperStyles as styles } from './flipper.styles';
name: 'fluent-flipper',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentFlipper extends Flipper {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/menu-item/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { MenuItemStyles as styles } from './menu-item.styles';
name: 'fluent-menu-item',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentMenuItem extends MenuItem {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/menu/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { MenuStyles as styles } from './menu.styles';
name: 'fluent-menu',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentMenu extends Menu {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/progress/progress-ring/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { ProgressRingStyles as styles } from './progress-ring.styles';
name: 'fluent-progress-ring',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentProgressRing extends BaseProgress {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/progress/progress/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { ProgressStyles as styles } from './progress.styles';
name: 'fluent-progress',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentProgress extends BaseProgress {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/radio-group/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { RadioGroupStyles as styles } from './radio-group.styles';
name: 'fluent-radio-group',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentRadioGroup extends RadioGroup {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/radio/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { RadioStyles as styles } from './radio.styles';
name: 'fluent-radio',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentRadio extends Radio {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/slider-label/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { SliderLabelStyles as styles } from './slider-label.styles';
name: 'fluent-slider-label',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentSliderLabel extends SliderLabel {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/slider/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { SliderStyles as styles } from './slider.styles';
name: 'fluent-slider',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentSlider extends Slider {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/switch/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { SwitchStyles as styles } from './switch.styles';
name: 'fluent-switch',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentSwitch extends Switch {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/tabs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { TabsStyles as styles } from './tabs.styles';
name: 'fluent-tabs',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentTabs extends Tabs {}
export * from './tab/';
Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/tabs/tab-panel/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { TabPanelStyles as styles } from './tab-panel.styles';
name: 'fluent-tab-panel',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentTabPanel extends TabPanel {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/tabs/tab/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { TabStyles as styles } from './tab.styles';
name: 'fluent-tab',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentTab extends Tab {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/text-area/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ export type TextAreaAppearance = 'filled' | 'outline';
name: 'fluent-text-area',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentTextArea extends TextArea {
/**
Expand Down
1 change: 1 addition & 0 deletions packages/web-components/src/text-field/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export type TextFieldAppearance = 'filled' | 'outline';
styles,
shadowOptions: {
delegatesFocus: true,
mode: 'closed',
},
})
export class FluentTextField extends TextField {
Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/tree-item/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { TreeItemStyles as styles } from './tree-item.styles';
name: 'fluent-tree-item',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentTreeItem extends TreeItem {}

Expand Down
3 changes: 3 additions & 0 deletions packages/web-components/src/tree-view/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { TreeViewStyles as styles } from './tree-view.styles';
name: 'fluent-tree-view',
template,
styles,
shadowOptions: {
mode: 'closed',
},
})
export class FluentTreeView extends TreeView {}

Expand Down

0 comments on commit d0d5148

Please sign in to comment.