Custom sidebar will render kepler.gl default side bar adding a wrapper component to edit its style
431412
function CustomSidebarFactory(CloseButton) {
  const SideBar = SidebarFactory(CloseButton);
  const CustomSidebar = (props) => (
    <StyledSideBarContainer>
      <SideBar {...props}/>
    </StyledSideBarContainer>
  );
  return CustomSidebar;
}
604989
function(options) {
        this.originHTML = this.$main.html();

        this.$main.addClass([defaultClass, options.customClass, prefix + options.theme].join(' '));

        if (options.size === 'large') {
            this.$main.addClass(largeClass);
        }

        if (options.text) {
            this.$main.html(options.text);
        }

        if (options.icon) {
            var iconName = !document.documentMode ? options.icon : window.bizui.codepoints[options.icon];
            this.$main.prepend('<i class="biz-icon">' + iconName + '</i> ');
        }

        if (options.disabled) {
            this.disable();
        }
    }
125970
function UMLPackageView() {
        UMLGeneralNodeView.apply(this, arguments);
        this.containerChangeable = true;
        this.fillColor = PreferenceManager.get("uml.package.fillColor", "#ffffff") || PreferenceManager.get("view.fillColor", "#ffffff");
    }
990754
function(element, options) {
        this.setElement(element);
        this.setOptions(options, this.element);

        // Set events
        this.addEvent('horizontalresize', 'window', $.debounce(this.onResize.bind(this)));

        this.initialize();

        // Render the matrix
        this.refresh();
    }
634106
function (wrapper) {
		var textNode = wrapper.element,
			renderer = this,
			forExport = renderer.forExport,
			lines = pick(wrapper.textStr, '').toString()
				.replace(/<(b|strong)>/g, '<span style="font-weight:bold">')
				.replace(/<(i|em)>/g, '<span style="font-style:italic">')
				.replace(/<a/g, '<span')
				.replace(/<\/(b|strong|i|em|a)>/g, '</span>')
				.split(/<br.*?>/g),
			childNodes = textNode.childNodes,
			styleRegex = /style="([^"]+)"/,
			hrefRegex = /href="(http[^"]+)"/,
			parentX = attr(textNode, 'x'),
			textStyles = wrapper.styles,
			width = textStyles && textStyles.width && pInt(textStyles.width),
			textLineHeight = textStyles && textStyles.lineHeight,
			i = childNodes.length;

		/// remove old text
		while (i--) {
			textNode.removeChild(childNodes[i]);
		}

		if (width && !wrapper.added) {
			this.box.appendChild(textNode); // attach it to the DOM to read offset width
		}

		// remove empty line at end
		if (lines[lines.length - 1] === '') {
			lines.pop();
		}

		// build the lines
		each(lines, function (line, lineNo) {
			var spans, spanNo = 0;

			line = line.replace(/<span/g, '|||<span').replace(/<\/span>/g, '</span>|||');
			spans = line.split('|||');

			each(spans, function (span) {
				if (span !== '' || spans.length === 1) {
					var attributes = {},
						tspan = doc.createElementNS(SVG_NS, 'tspan'),
						spanStyle; // #390
					if (styleRegex.test(span)) {
						spanStyle = span.match(styleRegex)[1].replace(/(;| |^)color([ :])/, '$1fill$2');
						attr(tspan, 'style', spanStyle);
					}
					if (hrefRegex.test(span) && !forExport) { // Not for export - #1529
						attr(tspan, 'onclick', 'location.href=\"' + span.match(hrefRegex)[1] + '\"');
						css(tspan, { cursor: 'pointer' });
					}

					span = (span.replace(/<(.|\n)*?>/g, '') || ' ')
						.replace(/&lt;/g, '<')
						.replace(/&gt;/g, '>');

					// Nested tags aren't supported, and cause crash in Safari (#1596)
					if (span !== ' ') {

						// add the text node
						tspan.appendChild(doc.createTextNode(span));

						if (!spanNo) { // first span in a line, align it to the left
							attributes.x = parentX;
						} else {
							attributes.dx = 0; // #16
						}

						// add attributes
						attr(tspan, attributes);

						// first span on subsequent line, add the line height
						if (!spanNo && lineNo) {

							// allow getting the right offset height in exporting in IE
							if (!hasSVG && forExport) {
								css(tspan, { display: 'block' });
							}

							// Set the line height based on the font size of either
							// the text element or the tspan element
							attr(
								tspan,
								'dy',
								textLineHeight || renderer.fontMetrics(
									/px$/.test(tspan.style.fontSize) ?
										tspan.style.fontSize :
										textStyles.fontSize
								).h,
								// Safari 6.0.2 - too optimized for its own good (#1539)
								// TODO: revisit this with future versions of Safari
								isWebKit && tspan.offsetHeight
							);
						}

						// Append it
						textNode.appendChild(tspan);

						spanNo++;

						// check width and apply soft breaks
						if (width) {
							var words = span.replace(/([^\^])-/g, '$1- ').split(' '), // #1273
								tooLong,
								actualWidth,
								clipHeight = wrapper._clipHeight,
								rest = [],
								dy = pInt(textLineHeight || 16),
								softLineNo = 1,
								bBox;

							while (words.length || rest.length) {
								delete wrapper.bBox; // delete cache
								bBox = wrapper.getBBox();
								actualWidth = bBox.width;
								tooLong = actualWidth > width;
								if (!tooLong || words.length === 1) { // new line needed
									words = rest;
									rest = [];
									if (words.length) {
										softLineNo++;

										if (clipHeight && softLineNo * dy > clipHeight) {
											words = ['...'];
											wrapper.attr('title', wrapper.textStr);
										} else {

											tspan = doc.createElementNS(SVG_NS, 'tspan');
											attr(tspan, {
												dy: dy,
												x: parentX
											});
											if (spanStyle) { // #390
												attr(tspan, 'style', spanStyle);
											}
											textNode.appendChild(tspan);

											if (actualWidth > width) { // a single word is pressing it out
												width = actualWidth;
											}
										}
									}
								} else { // append to existing line tspan
									tspan.removeChild(tspan.firstChild);
									rest.unshift(words.pop());
								}
								if (words.length) {
									tspan.appendChild(doc.createTextNode(words.join(' ').replace(/- /g, '-')));
								}
							}
						}
					}
				}
			});
		});
	}
919991
function initContextMenuContainer(params) {
          // Destructuring
          var customClass = params.customClass;

          var $ul = $('<ul>');
          $ul.addClass('dropdown-menu');
          $ul.attr({ 'role': 'menu' });
          $ul.css({
            display: 'block',
            position: 'absolute',
            left: params.event.pageX + 'px',
            top: params.event.pageY + 'px',
            'z-index': 10000
          });

          if(customClass) { $ul.addClass(customClass); }

          return $ul;
        }
177721
function generateLoaders(loader, loaderOptions) {
    const loaders = [ cssLoader ];
    if (loader) {
      loaders.push({
        loader: loader + '-loader',
        options: Object.assign({}, loaderOptions, {
          sourceMap: options.sourceMap,
        }),
      });
    }

    // Extract CSS when that option is specified
    // (which is the case during production build)
    if (options.extract) {
      return [ MiniCssExtractPlugin.loader ].concat(loaders);
    }
    return [ 'vue-style-loader' ].concat(loaders);
  }
912834
def add_sidebar(self, component: Component) -> None:
        
        if not self.sidebar:
            raise NoSidebarError('Set `sidebar=True` if you want to use the sidebar.')

        if not isinstance(component, Component):
            raise ValueError('component must be Component type, found {}'.format(component))
        # self._track_widget(widget)
        self._controllers.append(component)
73806
function toggleSideBySide(editor) {
    var cm = editor.codemirror;
    var wrapper = cm.getWrapperElement();
    var preview = wrapper.nextSibling;
    var toolbarButton = editor.toolbarElements['side-by-side'];
    var useSideBySideListener = false;
    if (/editor-preview-active-side/.test(preview.className)) {
        preview.className = preview.className.replace(
            /\s*editor-preview-active-side\s*/g, ''
        );
        toolbarButton.className = toolbarButton.className.replace(/\s*active\s*/g, '');
        wrapper.className = wrapper.className.replace(/\s*CodeMirror-sided\s*/g, ' ');
    } else {
        // When the preview button is clicked for the first time,
        // give some time for the transition from editor.css to fire and the view to slide from right to left,
        // instead of just appearing.
        setTimeout(function () {
            if (!cm.getOption('fullScreen'))
                toggleFullScreen(editor);
            preview.className += ' editor-preview-active-side';
        }, 1);
        toolbarButton.className += ' active';
        wrapper.className += ' CodeMirror-sided';
        useSideBySideListener = true;
    }

    // Hide normal preview if active
    var previewNormal = wrapper.lastChild;
    if (/editor-preview-active/.test(previewNormal.className)) {
        previewNormal.className = previewNormal.className.replace(
            /\s*editor-preview-active\s*/g, ''
        );
        var toolbar = editor.toolbarElements.preview;
        var toolbar_div = wrapper.previousSibling;
        toolbar.className = toolbar.className.replace(/\s*active\s*/g, '');
        toolbar_div.className = toolbar_div.className.replace(/\s*disabled-for-preview*/g, '');
    }

    var sideBySideRenderingFunction = function () {
        preview.innerHTML = editor.options.previewRender(editor.value(), preview);
    };

    if (!cm.sideBySideRenderingFunction) {
        cm.sideBySideRenderingFunction = sideBySideRenderingFunction;
    }

    if (useSideBySideListener) {
        preview.innerHTML = editor.options.previewRender(editor.value(), preview);
        cm.on('update', cm.sideBySideRenderingFunction);
    } else {
        cm.off('update', cm.sideBySideRenderingFunction);
    }

    // Refresh to fix selection being off (#309)
    cm.refresh();
}
781106
function RenderTexture (opts) {
    RenderTexture.superclass.constructor.call(this, opts)

    var width = opts.width,
        height = opts.height

    evt.addPropertyListener(this, 'contentSize', 'change', this._resizeCanvas.bind(this))

    this.canvas = document.createElement('canvas')
    this.context = this.canvas.getContext('2d')

    var atlas = new TextureAtlas({canvas: this.canvas})
    this.sprite = new Sprite({textureAtlas: atlas, rect: {origin: ccp(0, 0), size: {width: width, height: height}}})

    this.contentSize = geo.sizeMake(width, height)
    this.addChild(this.sprite)
    this.anchorPoint = ccp(0, 0)
    this.sprite.anchorPoint = ccp(0, 0)

}
731009
public static function dynamic_sidebar( $sidebar_id ) {
		if ( ! static::_is_caching_sidebars() ) {
			dynamic_sidebar( $sidebar_id );
			return;
		}

		if ( ! static::_is_caching_sidebar( $sidebar_id ) ) {
			dynamic_sidebar( $sidebar_id );
			return;
		}

		if ( is_customize_preview() ) {
			dynamic_sidebar( $sidebar_id );
			return;
		}

		$transient_id = static::get_transient_id( $sidebar_id );
		$transient    = get_transient( $transient_id );

		if ( false === $transient ) {
			ob_start();
			dynamic_sidebar( $sidebar_id );
			$transient = ob_get_clean();
			set_transient( $transient_id, $transient, HOUR_IN_SECONDS );
		}

		// @codingStandardsIgnoreStart
		echo '<!-- Cached sidebar ' . $sidebar_id . ' -->' . $transient . '<!-- /Cached sidebar ' . $sidebar_id . ' -->';
		// @codingStandardsIgnoreEnd
	}
153906
function(e,ellipseMode){
		var r = e.getRadii();
		if(ellipseMode === undefined){
			ellipseMode = this.app.CENTER;
		}
		if(ellipseMode === this.app.CENTER){
			this.gfx.ellipse(e.x,e.y,r.x*2,r.y*2);
		} else if(ellipseMode === this.app.RADIUS){
			this.gfx.ellipse(e.x,e.y,r.x*2,r.y*2);
		} else if(ellipseMode === this.app.CORNER || this.gfx.ellipseMode === this.app.CORNERS){
			this.gfx.ellipse(e.x-r.x,e.y-r.y,r.x*2,r.y*2);
		}
	}
759079
def render(self, **kwargs):
        """"""
        figure = self.get_root()
        assert isinstance(figure, Figure), ('You cannot render this Element '
                                            'if it is not in a Figure.')

        # Set global switches
        figure.header.add_child(self.global_switches, name='global_switches')

        # Import Javascripts
        for name, url in _default_js:
            figure.header.add_child(JavascriptLink(url), name=name)

        # Import Css
        for name, url in _default_css:
            figure.header.add_child(CssLink(url), name=name)

        figure.header.add_child(Element(
            '<style>html, body {'
            'width: 100%;'
            'height: 100%;'
            'margin: 0;'
            'padding: 0;'
            '}'
            '</style>'), name='css_style')

        figure.header.add_child(Element(
            '<style>#map {'
            'position:absolute;'
            'top:0;'
            'bottom:0;'
            'right:0;'
            'left:0;'
            '}'
            '</style>'), name='map_style')

        super(Map, self).render(**kwargs)
792397
function Renderer(options) {
  if (!(this instanceof Renderer)) {
    return new Renderer(options);
  }

  // create complete options object (using defaults)
  if (options) {
    debug("creating koa-handlebars instance with options", options);
  } else {
    debug("creating koa-handlebars instance");
  }

  var o = this.options = extend({}, Renderer.defaults, options);
  debug("using %s as the root", chalk.grey(o.root));

  // custom handlebars instance
  if (o.handlebars) {
    debug("using a custom handlebars instance");
    this.handlebars = o.handlebars;
  } else {
    this.handlebars = handlebars.create();
  }

  // register global helpers/partials
  if (o.helpers) this.helper(o.helpers);
  if (o.partials) this.partial(o.partials);

  // enabling caching (via lru-cache)
  if (o.cache) {
    debug("caching enabled");
    this.cache = new Cache({ max: 100 });
  }
}
1167929
@Override
	public void doRender(final WComponent component, final WebXmlRenderContext renderContext) {
		WColumn col = (WColumn) component;
		XmlStringBuilder xml = renderContext.getWriter();

		xml.appendTagOpen("ui:column");
		xml.appendAttribute("id", component.getId());
		xml.appendOptionalAttribute("class", component.getHtmlClass());
		xml.appendOptionalAttribute("track", component.isTracking(), "true");
		int width = col.getWidth();
		xml.appendOptionalAttribute("width", width > 0, width);

		switch (col.getAlignment()) {
			case LEFT:
				// left is assumed if omitted
				break;

			case RIGHT:
				xml.appendAttribute("align", "right");
				break;

			case CENTER:
				xml.appendAttribute("align", "center");
				break;

			default:
				throw new IllegalArgumentException("Invalid alignment: " + col.getAlignment());
		}

		xml.appendClose();

		// Paint column contents
		paintChildren(col, renderContext);

		xml.appendEndTag("ui:column");
	}
827393
function customize () {
  var q1 = {
    name: 'shortName',
    message: 'What is your component\'s name in usage? (e.g., `foo` for `aframe-foo-component`, `<a-entity foo="">`)',
    type: 'input',
    default: 'foo'
  };

  var q2 = {
    name: 'prettyName',
    message: 'What is your component\'s pretty name? (e.g., `Foo Bar` for `A-Frame Foo Bar Component`)',
    type: 'input',
    default: function (answers) {
      return titleCase(answers.shortName);
    }
  };

  var q3 = {
    name: 'description',
    message: 'Can you provide a short description of your component?',
    type: 'input',
    default: function (answers) {
      return `A ${answers.prettyName} component for A-Frame.`;
    }
  };

  var q4 = {
    name: 'repo',
    message: 'Where will your component live on Github? (e.g., `myusername/aframe-foo-component`)',
    type: 'input',
    default: function (answers) {
      return `myusername/aframe-${answers.shortName}-component`;
    }
  };

  var q5 = {
    name: 'author',
    message: 'Who are you? (e.g., `Jane John <jj@foo.com>`)',
    type: 'input',
    default: function () {
      return 'Jane John <jj@foo.com>';
    }
  };

  // Go.
  return new Promise(function (resolve) {
    inquirer.prompt([q1, q2, q3, q4, q5]).then(function (answers) {
      run(answers)
      resolve(answers.shortName);
    }, console.error);
  });

  /**
   * Do all the string replacements.
   */
  function run (answers) {
    ls(['LICENSE', 'package.json', 'README.md', 'index.js', 'index.html', 'examples/basic/index.html', 'tests/index.test.js']).forEach(function (file) {
      answers.aframeVersion = aframeVersion;
      answers.npmName = `aframe-${answers.shortName}-component`;
      fs.writeFileSync(file, nunjucks.render(file, answers));
    });
  }
}
1298212
function autocenter(options) {
    options = options || {};
    var needsCentering = false;
    var globe = null;

    var resize = function() {
      var width  = window.innerWidth + (options.extraWidth || 0);
      var height = window.innerHeight + (options.extraHeight || 0);
      globe.canvas.width = width;
      globe.canvas.height = height;
      globe.projection.translate([width / 2, height / 2]);
    };

    return function(planet) {
      globe = planet;
      planet.onInit(function() {
        needsCentering = true;
        d3.select(window).on('resize', function() {
          needsCentering = true;
        });
      });

      planet.onDraw(function() {
        if (needsCentering) { resize(); needsCentering = false; }
      });
    };
  }