UNPKG

@kiwicom/orbit-components

Version:

Orbit-components is a React component library which provides developers with the easiest possible way of building Kiwi.com’s products.

42 lines (41 loc) 1.95 kB
"use strict"; exports.__esModule = true; exports.default = void 0; var _consts = require("../consts"); const getButtonLinkTypeToken = (name, type, theme) => { const tokens = { [_consts.TOKENS.background]: { [_consts.TYPES.PRIMARY]: theme.orbit.buttonLinkPrimaryBackground, [_consts.TYPES.SECONDARY]: theme.orbit.buttonLinkSecondaryBackground, [_consts.TYPES.CRITICAL]: theme.orbit.buttonLinkCriticalBackground }, [_consts.TOKENS.backgroundHover]: { [_consts.TYPES.PRIMARY]: theme.orbit.buttonLinkPrimaryBackgroundHover, [_consts.TYPES.SECONDARY]: theme.orbit.buttonLinkSecondaryBackgroundHover, [_consts.TYPES.CRITICAL]: theme.orbit.buttonLinkCriticalBackgroundHover }, [_consts.TOKENS.backgroundActive]: { [_consts.TYPES.PRIMARY]: theme.orbit.buttonLinkPrimaryBackgroundActive, [_consts.TYPES.SECONDARY]: theme.orbit.buttonLinkSecondaryBackgroundActive, [_consts.TYPES.CRITICAL]: theme.orbit.buttonLinkCriticalBackgroundActive }, [_consts.TOKENS.foreground]: { [_consts.TYPES.PRIMARY]: theme.orbit.buttonLinkPrimaryForeground, [_consts.TYPES.SECONDARY]: theme.orbit.buttonLinkSecondaryForeground, [_consts.TYPES.CRITICAL]: theme.orbit.buttonLinkCriticalForeground }, [_consts.TOKENS.foregroundHover]: { [_consts.TYPES.PRIMARY]: theme.orbit.buttonLinkPrimaryForegroundHover, [_consts.TYPES.SECONDARY]: theme.orbit.buttonLinkSecondaryForegroundHover, [_consts.TYPES.CRITICAL]: theme.orbit.buttonLinkCriticalForegroundHover }, [_consts.TOKENS.foregroundActive]: { [_consts.TYPES.PRIMARY]: theme.orbit.buttonLinkPrimaryForegroundActive, [_consts.TYPES.SECONDARY]: theme.orbit.buttonLinkSecondaryForegroundActive, [_consts.TYPES.CRITICAL]: theme.orbit.buttonLinkCriticalForegroundActive } }; return tokens[name][type]; }; var _default = getButtonLinkTypeToken; exports.default = _default;