Files
classroomio/src/lib/utils/store/org.js
T
Rotimi BestandRotimi Best f39a0cee4b CLASSROOMIO-T-127: Theming configuration
CLASSROOMIO-T-127: Add 4 themes configurations into the app

Clean up


Co-authored-by: Rotimi Best <rotimiibitoyeemma@gmail.com>


Merge-request: CLASSROOMIO-MR-51
Merged-by: Best Admin <best@digdippa.com>
2023-08-20 19:08:48 +00:00

49 lines
1003 B
JavaScript

import cloneDeep from 'lodash/cloneDeep';
import { writable, derived } from 'svelte/store';
import { allOptions, STEPS, booleanOptions } from '../constants/quiz';
export const orgs = writable([]);
export const currentOrg = writable({
id: '',
name: '',
shortName: '',
siteName: '',
avatar_url: '',
theme: '',
memberId: ''
});
export const orgAudience = writable([]);
export const orgTeam = writable([]);
export const currentOrgPath = derived(currentOrg, ($currentOrg) =>
$currentOrg.siteName ? `/org/${$currentOrg.siteName}` : ''
);
// Quiz
export const createQuizModal = writable({
open: false,
openEdit: false,
title: '',
id: null
});
export const deleteModal = writable({
id: null,
open: false,
isQuestion: false
});
export const quizesStore = writable([]);
export const quizStore = writable({
uuid: '',
title: '',
questions: [],
timelimit: '10s',
theme: 'standard',
pin: ''
});
export const playQuizStore = writable({
step: STEPS.CONNECT_TO_PLAY
});