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BA,WACfuB,EAA4GvB,EAA5GuB,KAAMC,EAAsGxB,EAAtGwB,IAAKC,EAAiGzB,EAAjGyB,OAAQC,EAAyF1B,EAAzF0B,QAASC,EAAgF3B,EAAhF2B,WAAYC,EAAoE5B,EAApE4B,SAAUC,EAA0D7B,EAA1D6B,KAAMC,EAAoD9B,EAApD8B,OAAQC,EAA4C/B,EAA5C+B,cAAeC,EAA6BhC,EAA7BgC,kBAAmBC,EAAUjC,EAAViC,MAEpGC,GAAWC,EAAAA,EAAAA,QAAO,MAYxB,OAVAC,EAAAA,EAAAA,YAAU,WAAM,UAKL,GAJVT,EAAaO,SAAH,UAAGA,EAAUG,eAAb,OAAG,EAAmBC,aAAa,WAAY,IAAMJ,SAArD,UAAqDA,EAAUG,eAA/D,OAAqD,EAAmBf,gBAAgB,YAElG,UAAAiB,OAAM,WAAN,SAAeC,OAEVhB,KACJU,SAAA,UAAAA,EAAUG,eAAV,SAAmBf,gBAAgB,WAElC,IAEI,yBACNmB,UAAU,YACV,WAAUV,EAGV,oBAAuC,IAApBC,EAKnBU,KAAMlB,EACNC,OAAQA,EACRkB,IAAI,sBACJjB,QAASA,EACTkB,SAAS,MACTC,IAAKX,EACLY,GAAIb,GAEHL,IAAYE,aAAJ,EAAIA,EAAQN,MAAO,2BAAKuB,IAAKjB,aAAF,EAAEA,EAAQN,IAAKwB,IAAKlB,aAAF,EAAEA,EAAQkB,OAE9DpB,IAAYC,aAAb,EAAaA,EAAI,QAAW,yBAAGY,UAAWZ,aAAF,EAAEA,EAAI,QAE/C,4BAAMY,UAAU,UAAUhC,wBAAyB,CAAEC,OAAQa,O","sources":["webpack://button-block/external var \"React\"","webpack://button-block/external var \"ReactDOM\"","webpack://button-block/../Components/Helper/getCSS.js","webpack://button-block/./src/Style.js","webpack://button-block/./src/script.js"],"sourcesContent":["var __WEBPACK_NAMESPACE_OBJECT__ = React;","var __WEBPACK_NAMESPACE_OBJECT__ = ReactDOM;","export const getBackgroundCSS = (bg, isSolid = true, isGradient = true, isImage = true) => {\r\n\tconst { type = 'solid', color = '#000000b3', gradient = 'linear-gradient(135deg, #4527a4, #8344c5)', image = {}, position = 'center center', attachment = 'initial', repeat = 'no-repeat', size = 'cover', overlayColor = '#000000b3' } = bg;\r\n\r\n\tconst styles = ('gradient' === type && isGradient) ? `background: ${gradient};` :\r\n\t\t('image' === type && isImage) ?\r\n\t\t\t`background: url(${image?.url});\r\n\t\t\t\tbackground-color: ${overlayColor};\r\n\t\t\t\tbackground-position: ${position};\r\n\t\t\t\tbackground-size: ${size};\r\n\t\t\t\tbackground-repeat: ${repeat};\r\n\t\t\t\tbackground-attachment: ${attachment};\r\n\t\t\t\tbackground-blend-mode: overlay;` :\r\n\t\t\tisSolid && `background: ${color};`;\r\n\r\n\treturn styles;\r\n} // PHP version in Stepped Content\r\n\r\nexport const getBorderCSS = (border) => {\r\n\tconst { width = '0px', style = 'solid', color = '#0000', side = 'all', radius = '0px' } = border;\r\n\r\n\tconst borderSideCheck = s => {\r\n\t\tconst bSide = side?.toLowerCase();\r\n\t\treturn bSide?.includes('all') || bSide?.includes(s);\r\n\t}\r\n\r\n\tconst noWidth = width === '0px' || !width;\r\n\tconst borderCSS = `${width} ${style} ${color}`;\r\n\r\n\tconst styles = `\r\n\t\t${noWidth ? '' : borderSideCheck('top') ? `border-top: ${borderCSS};` : ''}\r\n\t\t${noWidth ? '' : borderSideCheck('right') ? `border-right: ${borderCSS};` : ''}\r\n\t\t${noWidth ? '' : borderSideCheck('bottom') ? `border-bottom: ${borderCSS};` : ''}\r\n\t\t${noWidth ? '' : borderSideCheck('left') ? `border-left: ${borderCSS};` : ''}\r\n\t\t${!radius ? '' : `border-radius: ${radius};`}\r\n\t`;\r\n\r\n\treturn styles;\r\n}\r\n\r\nexport const getColorsCSS = (colors) => {\r\n\tconst { color = '#333', bgType = 'solid', bg = '#0000', gradient = 'linear-gradient(135deg, #4527a4, #8344c5)' } = colors;\r\n\r\n\tconst styles = `\r\n\t\t${color ? `color: ${color};` : ''}\r\n\t\t${gradient || bg ? `background: ${'gradient' === bgType ? gradient : bg};` : ''}\r\n\t`;\r\n\r\n\treturn styles;\r\n}\r\n\r\nexport const getIconCSS = (icon, isSize = true, isColor = true) => {\r\n\tconst { fontSize = 16, colorType = 'solid', color = 'inherit', gradient = 'linear-gradient(135deg, #4527a4, #8344c5)' } = icon;\r\n\r\n\tconst colorCSS = 'gradient' === colorType ?\r\n\t\t`color: transparent; background-image: ${gradient}; -webkit-background-clip: text; background-clip: text;` :\r\n\t\t`color: ${color};`;\r\n\r\n\tconst styles = `\r\n\t\t${!fontSize || !isSize ? '' : `font-size: ${fontSize}px;`}\r\n\t\t${isColor ? colorCSS : ''}\r\n\t`;\r\n\r\n\treturn styles;\r\n}\r\n\r\nexport const getMultiShadowCSS = (value, type = 'box') => {\r\n\tlet styles = '';\r\n\r\n\tvalue?.map((item, index) => {\r\n\t\tconst { hOffset = '0px', vOffset = '0px', blur = '0px', spreed = '0px', color = '#7090b0', isInset = false } = item;\r\n\r\n\t\tconst inset = isInset ? 'inset' : '';\r\n\t\tconst offsetBlur = `${hOffset || ''} ${vOffset || ''} ${blur || ''}`;\r\n\t\tconst isComa = index + 1 >= value.length ? '' : ', ';\r\n\r\n\t\tstyles += 'text' === type ? `${offsetBlur} ${color || ''}${isComa}` : `${offsetBlur} ${spreed || ''} ${color || ''} ${inset}${isComa}`;\r\n\t});\r\n\r\n\treturn styles || 'none';\r\n}\r\n\r\nexport const getSeparatorCSS = (separator) => {\r\n\tconst { width = '50%', height = '2px', style = 'solid', color = '#bbb' } = separator;\r\n\r\n\tconst styles = `\r\n\t\twidth: ${width};\r\n\t\t${'0px' === height && '0em' === height && '0rem' === height ? '' : `border-top: ${height} ${style} ${color};`}\r\n\t`;\r\n\r\n\treturn styles;\r\n}\r\n\r\nexport const getShadowCSS = (shadow) => {\r\n\tconst { type = 'box', hOffset = '0px', vOffset = '0px', blur = '0px', spreed = '0px', color = '#7090b0', isInset = false } = shadow;\r\n\r\n\tconst inset = isInset ? 'inset' : '';\r\n\tconst offsetBlur = `${hOffset} ${vOffset} ${blur}`;\r\n\r\n\tconst styles = 'text' === type ? `${offsetBlur} ${color}` : `${offsetBlur} ${spreed} ${color} ${inset}`;\r\n\r\n\treturn styles || 'none';\r\n}\r\n\r\nexport const getSpaceCSS = (space) => {\r\n\tconst { side = 2, vertical = '0px', horizontal = '0px', top = '0px', right = '0px', bottom = '0px', left = '0px' } = space;\r\n\r\n\tconst styles = 2 === side ? `${vertical} ${horizontal}` : `${top} ${right} ${bottom} ${left}`;\r\n\r\n\treturn styles;\r\n}\r\n\r\nexport const getTypoCSS = (typo, isFamily = true) => {\r\n\tconst { fontFamily = 'Default', fontCategory = 'sans-serif', fontVariant = 400, fontWeight = 400, isUploadFont = true, fontSize = 15, fontStyle = 'normal', textTransform = 'none', textDecoration = 'auto', lineHeight = '135%', letterSpace = '0px' } = typo;\r\n\r\n\tconst generateCss = (value, cssProperty) => !value ? '' : `${cssProperty}: ${value};`;\r\n\r\n\tconst isEmptyFamily = !isFamily || !fontFamily || 'Default' === fontFamily;\r\n\r\n\tconst styles = `\r\n\t\t${isEmptyFamily ? '' : `font-family: '${fontFamily}', ${fontCategory};`}\r\n\t\t${generateCss(fontWeight, 'font-weight')}\r\n\t\t${!fontSize ? '' : `font-size: ${fontSize}px;`}\r\n\t\t${generateCss(fontStyle, 'font-style')}\r\n\t\t${generateCss(textTransform, 'text-transform')}\r\n\t\t${generateCss(textDecoration, 'text-decoration')}\r\n\t\t${generateCss(lineHeight, 'line-height')}\r\n\t\t${generateCss(letterSpace, 'letter-spacing')}\r\n\t`;\r\n\r\n\t// Google font link\r\n\tconst linkQuery = !fontVariant || 400 === fontVariant ? '' : '400i' === fontVariant ? ':ital@1' : fontVariant?.includes('00i') ? `: ital, wght@1, ${fontVariant?.replace('00i', '00')} ` : `: wght@${fontVariant} `;\r\n\r\n\tconst link = isEmptyFamily ? '' : `https://fonts.googleapis.com/css2?family=${fontFamily?.split(' ').join('+')}${linkQuery.replace(/ /g, '')}&display=swap`;\r\n\r\n\treturn {\r\n\t\tstyles: styles.replace(/\\s+/g, ' ').trim(),\r\n\t\tgoogleFontLink: !isUploadFont || isEmptyFamily ? '' : `@import url(${link});`\r\n\t};\r\n}","import { getBorderCSS, getColorsCSS, getMultiShadowCSS, getSpaceCSS, getTypoCSS } from '../../Components/Helper/getCSS';\r\n\r\nconst Style = ({ attributes, clientId }) => {\r\n\tconst { isFullWidth, addCSS, alignment, typography, colors, hovColors, padding, border, shadow } = attributes;\r\n\r\n\treturn <>\r\n\t\t