Skip to content

Commit

Permalink
AngularPluginBase: make plugins automatically readonly in answer revi…
Browse files Browse the repository at this point in the history
…ew mode
  • Loading branch information
dezhidki committed Feb 26, 2025
1 parent da5ea01 commit 846d9e0
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import {isLeft} from "fp-ts/Either";
import {getErrors} from "tim/plugin/errors";
import {vctrlInstance} from "tim/document/viewctrlinstance";
import type {ChangeType, ViewCtrl} from "tim/document/viewctrl";
import {Users} from "tim/user/userService";

/**
* Plugin with initialization data passed from the server via JSON.
Expand Down Expand Up @@ -103,7 +104,7 @@ export abstract class AngularPluginBase<
if (this.markup.readonly !== undefined) {
return this.markup.readonly;
}
return this.attrsall.access === "readonly";
return this.attrsall.access === "readonly" || Users.isInAnswerReview;
}

constructor(
Expand Down

0 comments on commit 846d9e0

Please sign in to comment.