501502if (mainPage.backgroundColor || mainPage.backgroundImage) {503textStyle += '#app {\n';504505if (mainPage.backgroundColor && !mainPage.backgroundImage) {506textStyle +=507' background-color: rgba(' +508tma__resources__hexToRgb(mainPage.backgroundColor).join(', ') +509', ' +510tma__resources__getOpacity(mainPage.backgroundColorOpacity) +511');\n';512}
if (mainPage.backgroundImage) { textStyle += 'background-image: url(' + mainPage.backgroundImage + ');\n'; if (mainPage.useBackgroundPattern) { textStyle += 'background-size: auto;\n'; textStyle += 'background-repeat: repeat;\n'; } else { textStyle += 'background-position: center;\n'; textStyle += 'background-size: cover;\n'; textStyle += 'background-repeat: no-repeat;\n'; } } textStyle += '}\n'; } if (mainPage.backgroundColor && mainPage.backgroundImage) { textStyle += '.tlk-app-bg {\n'; textStyle += ' background-color: rgba(' + tma__resources__hexToRgb(mainPage.backgroundColor).join(', ') + ', ' + tma__resources__getOpacity(mainPage.backgroundColorOpacity) + ');\n'; textStyle += '}\n'; } textStyle += '.tlk-resources__wrap {\n'; textStyle += ' min-height: 100%;\n'; textStyle += ' padding: 60px;\n'; if (mainPage.boxBackgroundColor || mainPage.boxBackgroundColorOpacity) { var boxBackgroundColor = mainPage.boxBackgroundColor ? tma__resources__hexToRgb(mainPage.boxBackgroundColor).join(', ') : '255, 255, 255'; textStyle += ' background-color: rgba(' + boxBackgroundColor + ', ' + tma__resources__getOpacity(mainPage.boxBackgroundColorOpacity) + ');\n'; } if (mainPage.boxRadius) { textStyle += ' border-radius: ' + mainPage.boxRadius + ';\n'; } if (mainPage.boxShadowColor || mainPage.boxShadowOpacity) { var boxShadowColor = mainPage.boxShadowColor ? tma__resources__hexToRgb(mainPage.boxShadowColor).join(', ') : '255, 255, 255'; var boxShadowColorOpacity = tma__resources__getOpacity(mainPage.boxShadowOpacity); textStyle += ' -webkit-box-shadow: 0 0 10px 0 rgba(' + boxShadowColor + ', ' + boxShadowColorOpacity + ');\n'; textStyle += ' box-shadow: 0 0 10px 0 rgba(' + boxShadowColor + ', ' + boxShadowColorOpacity + ');\n'; textStyle += ' -webkit-box-sizing: border-box;\n'; } if (mainPage.textAlign === 'center') { textStyle += ' text-align: center;\n'; } else if (mainPage.textAlign === 'right') { textStyle += ' text-align: right;\n'; } if (mainPage.textSize) { textStyle += ' font-size: ' + mainPage.textSize + ';\n'; } textStyle += '}\n'; if (mainPage.textSizeMobile) { textStyle += '@media screen and (max-width: 767px) {\n'; textStyle += ' .tlk-resources__wrap {\n'; textStyle += ' font-size: ' + mainPage.textSizeMobile + ';\n'; textStyle += ' }\n'; textStyle += '}\n'; } if (mainPage.textColor) { textStyle += '#allrecords [data-field="tlk-link"], [data-field="tlk-link"], .tlk-resources__title, .tlk-resources__empty-text {\n'; textStyle += ' color: ' + mainPage.textColor + ';\n'; textStyle += '}\n'; textStyle += '.tlk-resources__title span {\n'; textStyle += ' color: rgba(' + tma__resources__hexToRgb(mainPage.textColor).join(', ') + ', 0.6);\n'; textStyle += '}\n';