Skip to content

Commit

Permalink
Full revert for #8529
Browse files Browse the repository at this point in the history
  • Loading branch information
tsv2013 committed Jul 10, 2024
1 parent 10a0277 commit 5022180
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
6 changes: 6 additions & 0 deletions src/entries/jquery-ui.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,15 @@ jQuery["fn"].extend({
PopupSurvey: doPopupSurvey,
SurveyWindow: doPopupSurvey
});

function doPopupSurvey(props: any): void {
return this.each(function () {
var model: Survey = props.model;
const survey = React.createElement(PopupSurvey, { ...props });
ReactDOM.render(survey, this);

// var popupSurvey = props.popupModel || new PopupSurvey(model);

// if (props.expanded !== undefined) {
// popupSurvey.isExpanded = props.expanded;
// }
Expand All @@ -42,8 +45,11 @@ function doPopupSurvey(props: any): void {
// popupSurvey.show();
});
}

SurveyModel.platform = "jquery";

export const preact: any = React;

export * from "./jquery-ui-model";
export * from "./core-export";

Expand Down
4 changes: 3 additions & 1 deletion src/entries/react-ui.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,6 @@ export { SurveyModel as Model } from "survey-core";
export * from "../utils/responsivity-manager";
export { unwrap } from "../utils/utils";

import { checkLibraryVersion } from "survey-core";
import { checkLibraryVersion } from "survey-core";

checkLibraryVersion(`${process.env.VERSION}`, "survey-react-ui");
3 changes: 1 addition & 2 deletions src/react/reactquestion_file.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ import { ReactQuestionFactory } from "./reactquestion_factory";
import { attachKey2click } from "./reactSurvey";
import { LoadingIndicatorComponent } from "./components/loading-indicator";
import { SurveyAction } from "./components/action-bar/action-bar-item";
import { ReactElementFactory } from "./element-factory";
import { SurveyFileChooseButton } from "./components/file/file-choose-button";
import { ReactElementFactory, SurveyFileChooseButton } from "../entries/react-ui-model";

export class SurveyQuestionFile extends SurveyQuestionElementBase {
constructor(props: any) {
Expand Down

0 comments on commit 5022180

Please sign in to comment.