UNPKG

@yandex/ui

Version:

Yandex UI components

35 lines (34 loc) 1.42 kB
import React from 'react'; import { select, text, object } from '@storybook/addon-knobs'; import { Icon } from '@yandex-lego/components/Icon/bundle'; var types = ['arrow', 'close', 'cross', 'cross-websearch', 'filter']; var glyphs = [ 'carets-v', 'type-arrow', 'type-check', 'type-close', 'type-cross', 'type-cross-websearch', 'type-filter', 'type-indeterminate', 'type-tick', 'x-sign', ]; export var Playground = function () { var type = select('type', types, 'arrow'); var glyph = select('glyph', glyphs, 'type-arrow'); var url = text('url', 'https://yastatic.net/lego/_/Kx6F6RQnQFitm0qRxX7vpvfP0K0.png'); var style = object('style', { width: 16, hight: 16 }); return (React.createElement("table", { cellSpacing: 5, style: { textAlign: 'center' } }, React.createElement("tr", null, React.createElement("td", null, "_type"), React.createElement("td", null, "_glyph"), React.createElement("td", null, "url")), React.createElement("tr", null, React.createElement("td", null, React.createElement(Icon, { type: type, style: style })), React.createElement("td", null, React.createElement(Icon, { glyph: glyph, style: style })), React.createElement("td", null, React.createElement(Icon, { url: url, style: { width: 16 } }))))); };