Skip to content

Commit

Permalink
Rename CheckboxMaterialDesignComponent to CheckboxComponent
Browse files Browse the repository at this point in the history
  • Loading branch information
the-djmaze committed Oct 4, 2022
1 parent 74f8304 commit 1edc5fa
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions dev/App/Abstract.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { LanguageStore } from 'Stores/Language';
import { ThemeStore } from 'Stores/Theme';

import { SelectComponent } from 'Component/Select';
import { CheckboxMaterialDesignComponent } from 'Component/MaterialDesign/Checkbox';
import { CheckboxComponent } from 'Component/Checkbox';

export class AbstractApp {
/**
Expand All @@ -28,8 +28,8 @@ export class AbstractApp {
}

bootstart() {
const register = (key, ClassObject, templateID) => ko.components.register(key, {
template: { element: templateID || (key + 'Component') },
const register = (key, ClassObject) => ko.components.register(key, {
template: { element: key + 'Component' },
viewModel: {
createViewModel: (params, componentInfo) => {
params = params || {};
Expand All @@ -41,9 +41,8 @@ export class AbstractApp {
}
}
});

register('Select', SelectComponent);
register('Checkbox', CheckboxMaterialDesignComponent, 'CheckboxMaterialDesignComponent');
register('Checkbox', CheckboxComponent);

initOnStartOrLangChange();

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export class CheckboxMaterialDesignComponent {
export class CheckboxComponent {
constructor(params = {}) {
this.value = ko.isObservable(params.value) ? params.value
: ko.observable(!!params.value);
Expand Down

0 comments on commit 1edc5fa

Please sign in to comment.