How to use the @carbon/icons/lib/error/20 function in @carbon/icons

To help you get started, we’ve selected a few @carbon/icons 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 carbon-design-system / carbon-custom-elements / src / components / inline-loading / inline-loading.ts View on Github external
private _renderIcon() {
    const { status } = this;
    if (status === INLINE_LOADING_STATE.ERROR) {
      return Error20({
        class: `${prefix}--inline-loading--error`,
      });
    }
    if (status === INLINE_LOADING_STATE.FINISHED) {
      return CheckmarkFilled16({
        class: `${prefix}--inline-loading__checkmark-container ${prefix}--inline-loading__svg`,
      });
    }
    if (status === INLINE_LOADING_STATE.INACTIVE || status === INLINE_LOADING_STATE.ACTIVE) {
      const classes = classMap({
        [`${prefix}--loading ${prefix}--loading--small`]: true,
        [`${prefix}--loading--stop`]: status === INLINE_LOADING_STATE.INACTIVE,
      });
      return html`
        <div class="${classes}">
          ${getLoadingIcon({ type: LOADING_TYPE.SMALL })}</div>