Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
24dd626
Adding autoscroll utility and marquee selection.
dzearing Aug 1, 2016
3921752
More fixes.
dzearing Aug 3, 2016
d5ec54c
Merge pull request #1 from OfficeDev/master
dzearing Aug 3, 2016
58281d9
Enables selection preservation even when items dematerialize.
dzearing Aug 3, 2016
c4ced04
Math rounding tweak in auto scrolling.
dzearing Aug 3, 2016
2e0a119
Updating small nits.
dzearing Aug 3, 2016
ae2bd96
Merge pull request #2 from OfficeDev/master
dzearing Aug 4, 2016
1272674
Merge branch 'master' of https://github.com/dzearing/office-ui-fabric…
dzearing Aug 4, 2016
bb4d1c0
Adding example page, improving props documentation, adding memoizatio…
dzearing Aug 4, 2016
089fd22
More performance improvements.
dzearing Aug 5, 2016
456aee3
Moving files to a more logical location.
dzearing Aug 5, 2016
3c3b43d
Missing an index change.
dzearing Aug 5, 2016
66ef16d
Adding more best practices content.
dzearing Aug 5, 2016
6729ebd
Updating documentation.
dzearing Aug 5, 2016
9d12f13
Removing unnecessary call.
dzearing Aug 5, 2016
3c08105
Removing dir from html.
dzearing Aug 5, 2016
4295470
Removing an unnecessary measure from autoscroll.
dzearing Aug 6, 2016
0c7a8a4
Updating basic details list example to use marquee selection.
dzearing Aug 8, 2016
fb61f66
With scrolltop fix (#3)
dzearing Aug 8, 2016
7ade6e9
Improving the example by removing the images.
dzearing Aug 8, 2016
bd5777d
Removing the scroll monitoring and css tweaking from Fabric component…
dzearing Aug 8, 2016
dca18b5
Fixing issues related to safari support.
dzearing Aug 8, 2016
f329966
Minor improvement to EventGroup.
dzearing Aug 8, 2016
59ab874
Lint fixes.
dzearing Aug 8, 2016
4079b67
Updates for PR comments.
dzearing Aug 8, 2016
4a08c31
Fixing hovers.
dzearing Aug 8, 2016
c53a0ef
Updating checkbox to a cleaner contract. This is a breaking change fo…
dzearing Aug 8, 2016
5353922
Merge branch 'master' of https://github.com/OfficeDev/office-ui-fabri…
dzearing Aug 10, 2016
72e9387
Updating comments.
dzearing Aug 10, 2016
f12c51b
Minor pr updates.
dzearing Aug 10, 2016
2b28dac
Feedback.
dzearing Aug 10, 2016
56c7ef5
Updating focuszone to have inputProps.
dzearing Aug 10, 2016
60aa2bf
Merge branch 'master' of https://github.com/OfficeDev/office-ui-fabri…
dzearing Aug 10, 2016
25a345a
Tweaks to documentation.
dzearing Aug 10, 2016
94e1490
Adding a class interface.
dzearing Aug 10, 2016
37a2613
Merge branch 'master' of https://github.com/OfficeDev/office-ui-fabri…
dzearing Aug 11, 2016
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/components/Checkbox/Checkbox.Props.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ export interface ICheckboxProps extends React.Props<Checkbox> {
onChange?: (ev?: React.FormEvent, isChecked?: boolean) => void;

/**
* Input props that will be mixed into the input element, *before* other props are applied. This allows you to extend
* the input element with additional attributes, such as data-automation-id needed for automation. Note that if you
* provide, for example, "disabled" as well as "inputProps.disabled", the former will take precedence of the later.
* Optional input props that will be mixed into the input element, *before* other props are applied. This allows
* you to extend the input element with additional attributes, such as data-automation-id needed for automation.
* Note that if you provide, for example, "disabled" as well as "inputProps.disabled", the former will take
* precedence over the later.
*/
inputProps?: React.Props<HTMLInputElement>;
}
2 changes: 1 addition & 1 deletion src/components/CommandBar/CommandBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export class CommandBar extends React.Component<ICommandBarProps, ICommandBarSta
return (
<div className={ css('ms-CommandBar', className) } ref='commandBarRegion'>
{ searchBox }
<FocusZone direction={ FocusZoneDirection.horizontal } rootProps={ { role:'menubar' } }>
<FocusZone direction={ FocusZoneDirection.horizontal } rootProps={ { role: 'menubar' } }>
<div className='ms-CommandBar-primaryCommands' ref='commandSurface'>
{ renderedItems.map((item, index) => (
this._renderItemInCommandBar(item, index, expandedMenuItemKey)
Expand Down
6 changes: 2 additions & 4 deletions src/components/ContextualMenu/ContextualMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -187,13 +187,11 @@ export class ContextualMenu extends React.Component<IContextualMenuProps, IConte
<div ref={ (host: HTMLDivElement) => this._host = host} id={ id } className={ css('ms-ContextualMenu-container', className) }>
{ (items && items.length) ? (
<FocusZone
className={ 'ms-ContextualMenu is-open' }
direction={ FocusZoneDirection.vertical }
ariaLabelledBy={ labelElementId }
ref={ (focusZone) => this._focusZone = focusZone }
rootProps={ {
className: 'ms-ContextualMenu is-open',
role: 'menu'
} }
rootProps={ { role: 'menu' } }
>
<ul className='ms-ContextualMenu-list is-open' onKeyDown={ this._onKeyDown }>
{ items.map((item, index) => (
Expand Down
28 changes: 20 additions & 8 deletions src/components/FocusZone/FocusZone.Props.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,23 @@
import * as React from 'react';
import { FocusZone } from './FocusZone';

/**
* FocusZone component class interface.
*/
export interface IFocusZone {
/** Sets focus to the checkbox. */
focus(): void;
}

/**
* FocusZone component props.
*/
export interface IFocusZoneProps extends React.Props<FocusZone> {
/**
* Additional class name to provide on the root element, in addition to the ms-FocusZone class.
*/
className?: string;

/**
* Defines which arrows to react to.
* @default FocusZoneDirection.bidriectional
Expand Down Expand Up @@ -39,14 +55,10 @@ export interface IFocusZoneProps extends React.Props<FocusZone> {
onActiveElementChanged?: (element?: HTMLElement, ev?: React.FocusEvent) => void;

/**
* If provided, additional class name to provide on the root element.
*/
className?: string;

/**
* If provided, HTMLProps which will be mixed in onto the root element emitted by the FocusZone, before
* other props are applied. This allows you to extend the root element with additional attributes, such as
* data-automation-id needed for automation.
* Optional DIV props that will be mixed into the root element, *before* other props are applied. This allows you
* to extend the root element with additional attributes, such as data-automation-id needed for automation. Note
* that if you provide, for example, "ariaLabelledBy" as well as "rootProps.ariaLabelledBy", the former will take
* precedence over the later.
*/
rootProps?: React.HTMLProps<HTMLDivElement>;
}
Expand Down
10 changes: 7 additions & 3 deletions src/components/FocusZone/FocusZone.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
import * as React from 'react';
import { IFocusZoneProps, FocusZoneDirection } from './FocusZone.Props';
import {
FocusZoneDirection,
IFocusZone,
IFocusZoneProps
} from './FocusZone.Props';
import { EventGroup } from '../../utilities/eventGroup/EventGroup';
import { KeyCodes } from '../../utilities/KeyCodes';
import { getRTL } from '../../utilities/rtl';
Expand All @@ -26,7 +30,7 @@ interface IPoint {
top: number;
}

export class FocusZone extends React.Component<IFocusZoneProps, {}> {
export class FocusZone extends React.Component<IFocusZoneProps, {}> implements IFocusZone {

public static defaultProps: IFocusZoneProps = {
isCircularNavigation: false,
Expand Down Expand Up @@ -90,7 +94,7 @@ export class FocusZone extends React.Component<IFocusZoneProps, {}> {
return (
<div
{ ...rootProps }
className={ css('ms-FocusZone', className ) }
className={ css('ms-FocusZone', className) }
ref='root'
data-focuszone-id={ this._id }
aria-labelledby={ ariaLabelledBy }
Expand Down