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.

47 lines (43 loc) 1.79 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _consts = require("../consts"); const getButtonLinkTypeToken = (name, type, theme) => { const tokens = { [_consts.TOKENS.background]: { [_consts.TYPES.PRIMARY]: "transparent", [_consts.TYPES.SECONDARY]: "transparent", [_consts.TYPES.CRITICAL]: "transparent" }, [_consts.TOKENS.backgroundHover]: { [_consts.TYPES.PRIMARY]: theme.orbit.paletteProductLightHover, [_consts.TYPES.SECONDARY]: theme.orbit.paletteCloudLightHover, [_consts.TYPES.CRITICAL]: theme.orbit.paletteRedLightHover }, [_consts.TOKENS.backgroundActive]: { [_consts.TYPES.PRIMARY]: theme.orbit.paletteProductLightActive, [_consts.TYPES.SECONDARY]: theme.orbit.paletteCloudLightActive, [_consts.TYPES.CRITICAL]: theme.orbit.paletteRedLightActive }, [_consts.TOKENS.foreground]: { [_consts.TYPES.PRIMARY]: theme.orbit.colorTextButtonLinkPrimary, [_consts.TYPES.SECONDARY]: theme.orbit.colorTextButtonLinkSecondary, [_consts.TYPES.CRITICAL]: theme.orbit.paletteRedNormal }, [_consts.TOKENS.foregroundHover]: { [_consts.TYPES.PRIMARY]: theme.orbit.colorTextButtonLinkPrimaryHover, [_consts.TYPES.SECONDARY]: theme.orbit.colorTextButtonLinkSecondaryHover, [_consts.TYPES.CRITICAL]: theme.orbit.paletteRedDarkHover }, [_consts.TOKENS.foregroundActive]: { [_consts.TYPES.PRIMARY]: theme.orbit.colorTextButtonLinkPrimaryActive, [_consts.TYPES.SECONDARY]: theme.orbit.colorTextButtonLinkSecondaryActive, [_consts.TYPES.CRITICAL]: theme.orbit.paletteRedDarkActive } }; return tokens[name][type]; }; var _default = getButtonLinkTypeToken; exports.default = _default;