10 examples of 'material ui withstyles' in JavaScript

Every line of 'material ui withstyles' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your JavaScript code is secure.

All examples are scanned by Snyk Code

By copying the Snyk Code Snippets you agree to
this disclaimer
62protected materialDom(props) {
63 return (
64 <a className="material-icons" {...props}>
65 {props.children || 'menu'}
66 </a>
67 );
68}
Important

Use secure code every time

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

139materialDom(props) {
140 return (
141 <nav className="mdc-list" ref={this.setControlRef} {...props}>
142 {props.children}
143 </nav>
144 );
145}
46protected materialDom(props) {
47 let className;
48 if (props.z) {
49 className = 'mdc-elevation--z' + props.z;
50 }
51 return (
52 <p className={className} {...props} ref={this.setControlRef}>
53 {props.children}
54 </p>
55 );
56}
40generateStyles() {
41 this.styles = StyleSheet.create({});
42}
32function useStyles(): CodeSurferStyles {
33 const { theme } = useThemeUI();
34 return (theme as any).styles.CodeSurfer;
35}
32static get styles() {
33 return [
34 css`
35 button {
36 color: red;
37 }
38
39 div {
40 ${unsafeCSS("color: red")};
41 }
42 `
43 ];
44}
20protected materialDom(props) {
21 return <div {...props}>{this.props.children}</div>;
22}
21protected materialDom(props) {
22 return (
23 <a role="option" {...props} ref={this.setControlRef}>
24 {props.children}
25 </a>
26 );
27}
37function Materialbox(el, options) {
38 _classCallCheck(this, Materialbox);
39
40 var _this = _possibleConstructorReturn(this, (Materialbox.__proto__ || Object.getPrototypeOf(Materialbox)).call(this, Materialbox, el, options));
41
42 _this.el.M_Materialbox = _this;
43
44 /**
45 * Options for the modal
46 * @member Materialbox#options
47 * @prop {Number} [inDuration=275] - Length in ms of enter transition
48 * @prop {Number} [outDuration=200] - Length in ms of exit transition
49 * @prop {Function} onOpenStart - Callback function called before materialbox is opened
50 * @prop {Function} onOpenEnd - Callback function called after materialbox is opened
51 * @prop {Function} onCloseStart - Callback function called before materialbox is closed
52 * @prop {Function} onCloseEnd - Callback function called after materialbox is closed
53 */
54 _this.options = $.extend({}, Materialbox.defaults, options);
55
56 _this.overlayActive = false;
57 _this.doneAnimating = true;
58 _this.placeholder = $('<div></div>').addClass('material-placeholder');
59 _this.originalWidth = 0;
60 _this.originalHeight = 0;
61 _this.originInlineStyles = _this.$el.attr('style');
62 _this.caption = _this.el.getAttribute('data-caption') || '';
63
64 // Wrap
65 _this.$el.before(_this.placeholder);
66 _this.placeholder.append(_this.$el);
67
68 _this._setupEventHandlers();
69 return _this;
70}
39protected materialDom(allprops) {
40 const {children, ...props} = allprops;
41 const otherprops: {[prop: string]: any} = {};
42 if (props.trailing) {
43 otherprops.tabindex = 0;
44 otherprops.role = 'button';
45 }
46 return (
47 <Icon {...props} {...otherprops}>
48 {children}
49 </Icon>
50 );
51}

Related snippets