(scheduler2)
| 7460 | }; |
| 7461 | } |
| 7462 | function extend$3(scheduler2) { |
| 7463 | scheduler2._addThemeClass = function() { |
| 7464 | document.documentElement.setAttribute("data-scheduler-theme", scheduler2.skin); |
| 7465 | }; |
| 7466 | scheduler2._skin_settings = { fix_tab_position: [1, 0], use_select_menu_space: [1, 0], wide_form: [1, 0], hour_size_px: [44, 42], displayed_event_color: ["#ff4a4a", "ffc5ab"], displayed_event_text_color: ["#ffef80", "7e2727"] }; |
| 7467 | scheduler2._skin_xy = { lightbox_additional_height: [90, 50], nav_height: [59, 22], bar_height: [24, 20] }; |
| 7468 | scheduler2._is_material_skin = function() { |
| 7469 | if (!scheduler2.skin) { |
| 7470 | return checkIfMaterialSkin(); |
| 7471 | } else { |
| 7472 | return (scheduler2.skin + "").indexOf("material") > -1; |
| 7473 | } |
| 7474 | }; |
| 7475 | function themeNameFromFile() { |
| 7476 | var links = document.getElementsByTagName("link"); |
| 7477 | for (var i = 0; i < links.length; i++) { |
| 7478 | var res = links[i].href.match("dhtmlxscheduler_([a-z]+).css"); |
| 7479 | if (res) { |
| 7480 | return res[1]; |
| 7481 | } |
| 7482 | } |
| 7483 | } |
| 7484 | scheduler2._build_skin_info = function() { |
| 7485 | monitorThemeChange(); |
| 7486 | const styles = getComputedStyle(this.$container); |
| 7487 | const themeVar = styles.getPropertyValue("--dhx-scheduler-theme"); |
| 7488 | let isCssVarTheme = !!themeVar; |
| 7489 | let themeName; |
| 7490 | let cssValues = {}; |
| 7491 | let oldMaterialTheme = false; |
| 7492 | if (isCssVarTheme) { |
| 7493 | themeName = themeVar; |
| 7494 | for (let i in scheduler2.xy) { |
| 7495 | cssValues[i] = styles.getPropertyValue(`--dhx-scheduler-xy-${i}`); |
| 7496 | } |
| 7497 | cssValues.hour_size_px = styles.getPropertyValue(`--dhx-scheduler-config-hour_size_px`); |
| 7498 | cssValues.wide_form = styles.getPropertyValue(`--dhx-scheduler-config-form_wide`); |
| 7499 | } else { |
| 7500 | themeName = themeNameFromFile(); |
| 7501 | oldMaterialTheme = scheduler2._is_material_skin(); |
| 7502 | } |
| 7503 | scheduler2._theme_info = { theme: themeName, cssVarTheme: isCssVarTheme, oldMaterialTheme, values: cssValues }; |
| 7504 | if (scheduler2._theme_info.cssVarTheme) { |
| 7505 | const themeVariables = this._theme_info.values; |
| 7506 | for (let i in scheduler2.xy) { |
| 7507 | if (!isNaN(parseInt(themeVariables[i]))) { |
| 7508 | scheduler2.xy[i] = parseInt(themeVariables[i]); |
| 7509 | } |
| 7510 | } |
| 7511 | } |
| 7512 | }; |
| 7513 | var calculatedMaterial; |
| 7514 | function checkIfMaterialSkin() { |
| 7515 | if (calculatedMaterial === void 0) { |
| 7516 | var probe = document.createElement("div"); |
| 7517 | probe.style.position = "absolute"; |
| 7518 | probe.style.left = "-9999px"; |
| 7519 | probe.style.top = "-9999px"; |
no test coverage detected