Skip to content
Snippets Groups Projects
Commit 2756ba68 authored by RMidhunSuresh's avatar RMidhunSuresh
Browse files

Create a vm for footer

parent e1fae73a
No related branches found
No related tags found
No related merge requests found
import { ViewModel } from "hydrogen-view-sdk";
import { IChatterboxConfig } from "../types/IChatterboxConfig";
export class FooterViewModel extends ViewModel {
private _config: IChatterboxConfig;
constructor(options) {
super(options);
this._config = options.config;
}
openChatterboxLink() {
const link = this._config.footer?.chatterbox_link;
if (link) {
(window as any).sendOpenLink(link);
}
}
openMatrixLink() {
const link = this._config.footer?.matrix_link;
if (link) {
(window as any).sendOpenLink(link);
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment