Skip to content

CSS + JS (Angular / vanilla) ​

The @antumo/design npm package delivers the full design system as CSS + zero-dependency JavaScript.

CSS ​

SCSS import (bundlers) ​

scss
@use '@antumo/design';

Includes tokens (CSS variables), component classes, and utilities.

html
<link rel="stylesheet" href="node_modules/@antumo/design/web/dist/antumo.css">

Tokens only ​

If you only need the design tokens (colors, typography, spacing, effects) without component classes:

scss
@use '@antumo/design/tokens';

JavaScript ​

Two approaches — choose one.

A. Data attributes (no bundler) ​

For Blazor, ASP.NET MVC, vanilla HTML. Add a single <script> and drive everything with HTML attributes.

html
<script src="node_modules/@antumo/design/web/dist/antumo.min.js"></script>

Auto-init runs on DOMContentLoaded. Example — a modal:

html
<button data-antumo-toggle="modal" data-antumo-target="#myModal">Open</button>

<div class="modal" id="myModal" style="display:none">
  <div class="modal-content" role="dialog" tabindex="-1">
    <div class="modal-header">
      <h2>Title</h2>
      <button class="modal-header-close" data-antumo-dismiss="modal">Close</button>
    </div>
    <div class="modal-body">Hello, world.</div>
  </div>
</div>

Overlay click + Escape close automatically. Focus trap and scroll lock are handled.

B. Imperative API (ESM) ​

For Angular, React, or any bundler with ESM support:

typescript
import { Modal, Sidebar, Tooltip, autoInit } from '@antumo/design/js';

const modal = Modal.getOrCreateInstance(document.querySelector('#myModal'));
modal.show(triggerEl); // triggerEl regains focus on close
modal.hide();

// or let data attributes work:
autoInit();

Types ship with the package (@antumo/design/js exposes .d.ts), so you get full IntelliSense.

Angular + PrimeNG ​

typescript
// app.config.ts
import { providePrimeNG } from 'primeng/config';
import AntumoPreset from '@antumo/design/primeng';

export const appConfig = {
  providers: [
    providePrimeNG({
      theme: {
        preset: AntumoPreset,
        options: { darkModeSelector: '[data-theme="dark"]' },
      },
    }),
  ],
};

Import CSS in angular.json:

json
"styles": ["node_modules/@antumo/design/web/dist/antumo.css"]

Data attributes reference ​

AttributeValuePurpose
data-antumo-togglemodal / sidebar / tooltipTrigger an action
data-antumo-targetCSS selectorTarget element
data-antumo-dismissmodalClose nearest component
data-antumo-placementtop / bottom / left / rightTooltip position
data-antumo-persisttrue / falseSidebar: save state to localStorage

Events ​

All events bubble as antumo:{component}:{action} (e.g. antumo:modal:shown). Before-events (:show, :hide) are cancelable:

javascript
el.addEventListener('antumo:modal:hide', (e) => {
  if (hasUnsavedChanges) e.preventDefault();
});

See the component catalog for markup of every component.

Private package — internal use only (UNLICENSED).