diff --git a/CHANGELOG.md b/CHANGELOG.md index 06c0551ff0..10018997f3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines. +## [1.9.98](https://github.com/surveyjs/survey-library/compare/v1.9.97...v1.9.98) (2023-07-18) + ## [1.9.97](https://github.com/surveyjs/survey-library/compare/v1.9.96...v1.9.97) (2023-07-12) diff --git a/package.json b/package.json index edc2b82061..ba319e0449 100644 --- a/package.json +++ b/package.json @@ -81,7 +81,7 @@ "testcafe:ci:angular": "testcafe -c 4 -q attemptLimit=5,successThreshold=1 chrome:headless testCafe/ --app \"http-server ./packages/survey-angular-ui/example/dist --proxy http://localhost:8080? -p 8080\" --selector-timeout 1500 --reporter minimal --env=angular", "prepare": "husky install" }, - "version": "1.9.97", + "version": "1.9.98", "name": "survey-library", "private": true, "devDependencies": { diff --git a/packages/survey-angular-ui/CHANGELOG.md b/packages/survey-angular-ui/CHANGELOG.md index a011932e01..d0f7ec64e8 100644 --- a/packages/survey-angular-ui/CHANGELOG.md +++ b/packages/survey-angular-ui/CHANGELOG.md @@ -2,6 +2,8 @@ All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines. +## [1.9.98](https://github.com/surveyjs/surveyjs/compare/v1.9.97...v1.9.98) (2023-07-18) + ## [1.9.97](https://github.com/surveyjs/surveyjs/compare/v1.9.96...v1.9.97) (2023-07-12) diff --git a/packages/survey-angular-ui/package.json b/packages/survey-angular-ui/package.json index 52bb67e69e..84ac836908 100644 --- a/packages/survey-angular-ui/package.json +++ b/packages/survey-angular-ui/package.json @@ -1,6 +1,6 @@ { "name": "survey-angular-ui", - "version": "1.9.97", + "version": "1.9.98", "description": "survey.js is a JavaScript Survey Library. It is a modern way to add a survey to your website. It uses JSON for survey metadata and results.", "keywords": [ "Survey", diff --git a/src/stylesmanager.ts b/src/stylesmanager.ts index cd32b83b7e..d1c5bac4c7 100644 --- a/src/stylesmanager.ts +++ b/src/stylesmanager.ts @@ -282,6 +282,7 @@ export class StylesManager { return themeMapper; } static getIncludedThemeCss(): Array { + if (typeof settings.environment === "undefined") return []; const { rootElement }: ISurveyEnvironment = settings.environment; const themeMapper = StylesManager.getAvailableThemes(); @@ -324,6 +325,7 @@ export class StylesManager { } public static applyTheme(themeName: string = "default", themeSelector?: string): void { + if (typeof settings.environment === "undefined") return; const { rootElement }: ISurveyEnvironment = settings.environment; const element = isShadowDOM(rootElement) ? rootElement.host : rootElement; surveyCss.currentType = themeName; diff --git a/src/svgbundle.ts b/src/svgbundle.ts index ed5552ab8b..de25b86eb5 100644 --- a/src/svgbundle.ts +++ b/src/svgbundle.ts @@ -54,7 +54,7 @@ export class SvgIconRegistry { } public renderIcons() { const containerId = "sv-icon-holder-global-container"; - if(!settings.environment.root.getElementById(containerId)) { + if(!!settings.environment && !settings.environment.root.getElementById(containerId)) { let iconsDiv = document.createElement("div"); iconsDiv.id = containerId; iconsDiv.innerHTML = "" + this.iconsRenderedHtml() + "";