How to use the @uifabric/utilities.css function in @uifabric/utilities

To help you get started, we’ve selected a few @uifabric/utilities examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github microsoft / accessibility-insights-web / src / common / components / cards / simple-card-row.tsx View on Github external
export const SimpleCardRow = NamedFC('SimpleCardRow', ({ label: givenLabel, content, rowKey, contentClassName }) => {
    const contentStyling = css(styles.instanceListRowContent, contentClassName);

    return (
        
            {givenLabel}
            {content}
        
    );
});
github microsoft / accessibility-insights-web / src / reports / components / report-sections / details-section.tsx View on Github external
const createListItem = (icon: JSX.Element, label: string, content: string | JSX.Element, contentClassName?: string) => (
        <li>
            <span aria-hidden="true">
                {icon}
            </span>
            <span>{label}</span>
            <span>{content}</span>
        </li>
    );
github microsoft / accessibility-insights-web / src / common / components / collapsible-component.tsx View on Github external
public render(): JSX.Element {
        const showContent = this.state.showContent;
        let iconName = this.iconNameUp;
        let content = null;

        if (showContent) {
            iconName = this.iconNameDown;
            content = <div>{this.props.content}</div>;
        }

        return (
            <div>
                
                    <span>{this.props.header}</span>
                
                {content}
            </div>
        );
    }
}
github OfficeDev / office-ui-fabric-react / packages / date-time / src / components / Calendar / Calendar.base.tsx View on Github external
});

    let todayDateString: string = '';
    let selectedDateString: string = '';
    if (dateTimeFormatter &amp;&amp; strings!.todayDateFormatString) {
      todayDateString = format(strings!.todayDateFormatString, dateTimeFormatter.formatMonthDayYear(today!, strings!));
    }
    if (dateTimeFormatter &amp;&amp; strings!.selectedDateFormatString) {
      selectedDateString = format(strings!.selectedDateFormatString, dateTimeFormatter.formatMonthDayYear(selectedDate!, strings!));
    }
    const selectionAndTodayString = selectedDateString + ', ' + todayDateString;

    return (
      <div aria-label="{selectionAndTodayString}">
        <div aria-atomic="true" aria-live="polite">
          <span>{selectedDateString}</span>
        </div>
        {isDayPickerVisible &amp;&amp; (
          </div>
github OfficeDev / office-ui-fabric-react / packages / date-time / src / components / CalendarDayGrid / CalendarDayGrid.base.tsx View on Github external
private renderDayCells = (
    classNames: IProcessedStyleSet,
    day: IDayInfo,
    dayIndex: number,
    weekIndex: number,
    weekCorners?: IWeekCorners,
    ariaHidden?: boolean
  ): JSX.Element =&gt; {
    const { navigatedDate, dateTimeFormatter, allFocusable, strings } = this.props;
    const { activeDescendantId } = this.state;
    const isNavigatedDate = compareDates(navigatedDate, day.originalDate);

    return (
       {
          this.props.customDayCellRef &amp;&amp; this.props.customDayCellRef(element, day.originalDate, classNames);
          this._setDayCellRef(element, day, isNavigatedDate);
        }}
        aria-hidden={ariaHidden}
        onClick={day.isInBounds &amp;&amp; !ariaHidden ? day.onSelected : undefined}
        onMouseOver={!ariaHidden ? this.onMouseOverDay(day) : undefined}
        onMouseDown={!ariaHidden ? this.onMouseDownDay(day) : undefined}
        onMouseUp={!ariaHidden ? this.onMouseUpDay(day) : undefined}
        onMouseOut={!ariaHidden ? this.onMouseOutDay(day) : undefined}
github microsoft / accessibility-insights-web / src / DetailsView / components / assessment-instance-details-column.tsx View on Github external
public render(): JSX.Element {
        const showLabel = !!this.props.labelText;
        const showHeader = !!this.props.headerText;
        const textContent = this.props.textContent;

        const classNames = css('assessment-instance-label', this.props.customClassName);

        return (
            <div>
                {showLabel ? (
                    <div style="{{">
                        {this.props.labelText}
                    </div>
                ) : null}
                <div>
                    
                        <div>
                            {showHeader ? <strong>{this.props.headerText} </strong> : null}
                            <div>{textContent}</div>
                        </div>
                    
                </div></div>
github microsoft / accessibility-insights-web / src / common / components / cards / simple-card-row.tsx View on Github external
export const SimpleCardRow = NamedFC('SimpleCardRow', ({ label: givenLabel, content, rowKey, contentClassName }) =&gt; {
    const contentStyling = css(styles.instanceListRowContent, contentClassName);

    return (
        
            {givenLabel}
            {content}
        
    );
});
github microsoft / accessibility-insights-web / src / common / components / cards / collapsible-component-cards.tsx View on Github external
deps,
            buttonAriaLabel,
            containerAutomationId,
            containerClassName,
            header,
            id,
        } = props;

        const containerProps = { role: 'heading', 'aria-level': headingLevel };
        let contentWrapper = null;
        let collapsedCSSClassName = 'collapsed';

        const showContent = isExpanded || false;

        if (showContent) {
            contentWrapper = <div>{content}</div>;
            collapsedCSSClassName = null;
        }

        const onClick = (event: React.MouseEvent) =&gt; deps.cardSelectionMessageCreator.toggleRuleExpandCollapse(id, event);

        return (
            <div data-automation-id="{containerAutomationId}">
                <div>
                    </div></div>
github OfficeDev / office-ui-fabric-react / packages / example-component / src / ExampleComponent.tsx View on Github external
return (
        <a>
      );
    } else {
      const buttonProps: React.HTMLAttributes =
        getNativeProps(this.props, buttonProperties);

      return (
        <button>
      );
    }
  }
</button></a>
github OfficeDev / office-ui-fabric-react / packages / example-component / src / ExampleComponent.tsx View on Github external
private _onRenderChildren(): JSX.Element {
    const {
      children,
      onRenderIcon = this._onRenderIcon,
      onRenderText = this._onRenderText,
      onRenderChevron = this._onRenderChevron
    } = this.props;

    return (
      <div>
        { onRenderIcon(this.props, this._onRenderIcon) }
        { onRenderText(this.props, this._onRenderText) }
        { children }
        { onRenderChevron(this.props, this._onRenderChevron) }
      </div>
    );
  }