2020-12-15 08:38:17 +02:00
|
|
|
export type DocVar = {
|
|
|
|
name: string;
|
|
|
|
val: string;
|
|
|
|
};
|
|
|
|
|
2020-08-19 18:53:35 +03:00
|
|
|
export class Settings {
|
|
|
|
_docId: string | null = null;
|
2020-12-15 08:38:17 +02:00
|
|
|
_docVars: DocVar[] = [];
|
2021-03-26 06:37:01 +02:00
|
|
|
_defaultTabStop = 840;
|
2020-08-19 18:53:35 +03:00
|
|
|
|
|
|
|
docId(id: string) {
|
|
|
|
this._docId = id;
|
|
|
|
return this;
|
|
|
|
}
|
2020-12-15 08:38:17 +02:00
|
|
|
|
2021-03-26 06:37:01 +02:00
|
|
|
defaultTabStop(stop: number) {
|
|
|
|
this._defaultTabStop = stop;
|
|
|
|
return this;
|
|
|
|
}
|
|
|
|
|
2020-12-15 08:38:17 +02:00
|
|
|
addDocVar(name: string, val: string) {
|
|
|
|
this._docVars.push({ name, val });
|
|
|
|
return this;
|
|
|
|
}
|
2020-08-19 18:53:35 +03:00
|
|
|
}
|