UNPKG

@atlaskit/navigation-system

Version:

The latest navigation system for Atlassian apps.

7 lines • 228 B
export function resolveLayoutWidth(bound, viewportWidth) { if (typeof bound === 'number') { return bound; } const value = Number.parseFloat(bound); return bound.endsWith('vw') ? viewportWidth * value / 100 : value; }