updated imports
This commit is contained in:
@@ -13,14 +13,9 @@ from pydantic import ValidationError
|
||||
from pymongo.collection import Collection
|
||||
|
||||
from shared.data_store import delete as delete_from_minio
|
||||
from shared.dto import ModelData
|
||||
from shared.mongodb import (
|
||||
NoDocumentFoundException,
|
||||
VisualCommunication,
|
||||
count_documents,
|
||||
get_visual_communication,
|
||||
upsert_annotation,
|
||||
)
|
||||
from shared.mongodb import count_documents, get_visual_communication, upsert_annotation
|
||||
from shared.mongodb.classes import ModelData, VisualCommunication
|
||||
from shared.mongodb.exceptions import NoDocumentFoundException
|
||||
|
||||
from .layout import app_layout
|
||||
|
||||
|
||||
@@ -1,20 +1,21 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import dash_mantine_components as dmc
|
||||
from dash import dcc
|
||||
from dash import html
|
||||
from dash import dcc, html
|
||||
|
||||
from shared.dto import AngleData
|
||||
from shared.dto import ContactData
|
||||
from shared.dto import DistanceData
|
||||
from shared.dto import FramingData
|
||||
from shared.dto import InformationValueData
|
||||
from shared.dto import ModalityColorData
|
||||
from shared.dto import ModalityDepthData
|
||||
from shared.dto import ModalityLightingData
|
||||
from shared.dto import PointOfViewData
|
||||
from shared.dto import SalienceData
|
||||
from shared.dto import VisualSyntaxData
|
||||
from shared.mongodb.classes import (
|
||||
AngleData,
|
||||
ContactData,
|
||||
DistanceData,
|
||||
FramingData,
|
||||
InformationValueData,
|
||||
ModalityColorData,
|
||||
ModalityDepthData,
|
||||
ModalityLightingData,
|
||||
PointOfViewData,
|
||||
SalienceData,
|
||||
VisualSyntaxData,
|
||||
)
|
||||
|
||||
|
||||
def generate_visual_syntax_options_map():
|
||||
@@ -54,54 +55,63 @@ experiential_map = generate_visual_syntax_options_map()
|
||||
experiential_container = dmc.Col(
|
||||
children=[
|
||||
html.H4('experiential'.title()),
|
||||
], span=5,
|
||||
],
|
||||
span=5,
|
||||
)
|
||||
for title, options in experiential_map.items():
|
||||
id_dict = {'type': 'annotation', 'index': title.replace('_', '-')}
|
||||
experiential_container.children.append(
|
||||
dmc.Container([
|
||||
html.B(title.title()),
|
||||
dcc.RadioItems(
|
||||
options=[text.replace('_', ' ') for text in options],
|
||||
id=id_dict,
|
||||
),
|
||||
]),
|
||||
dmc.Container(
|
||||
[
|
||||
html.B(title.title()),
|
||||
dcc.RadioItems(
|
||||
options=[text.replace('_', ' ') for text in options],
|
||||
id=id_dict,
|
||||
),
|
||||
],
|
||||
),
|
||||
)
|
||||
# prepare interpersonal container
|
||||
interpersonal_map = generate_interpersonal_options_map()
|
||||
interpersonal_container = dmc.Col(
|
||||
children=[
|
||||
html.H4('interpersonal'.title()),
|
||||
], span=3,
|
||||
],
|
||||
span=3,
|
||||
)
|
||||
for title, options in interpersonal_map.items():
|
||||
id_dict = {'type': 'annotation', 'index': title.replace('_', '-')}
|
||||
interpersonal_container.children.append(
|
||||
dmc.Container([
|
||||
html.B(title.title()),
|
||||
dcc.RadioItems(
|
||||
options=[text.replace('_', ' ') for text in options],
|
||||
id=id_dict,
|
||||
),
|
||||
]),
|
||||
dmc.Container(
|
||||
[
|
||||
html.B(title.title()),
|
||||
dcc.RadioItems(
|
||||
options=[text.replace('_', ' ') for text in options],
|
||||
id=id_dict,
|
||||
),
|
||||
],
|
||||
),
|
||||
)
|
||||
# prepare textual container
|
||||
textual_map = generate_textual_options_map()
|
||||
textual_container = dmc.Col(
|
||||
children=[
|
||||
html.H4('textual'.title()),
|
||||
], span=4,
|
||||
],
|
||||
span=4,
|
||||
)
|
||||
for title, options in textual_map.items():
|
||||
id_dict = {'type': 'annotation', 'index': title.replace('_', '-')}
|
||||
textual_container.children.append(
|
||||
dmc.Container([
|
||||
html.B(title.title()),
|
||||
dcc.RadioItems(
|
||||
options=[text.replace('_', ' ') for text in options],
|
||||
id=id_dict,
|
||||
),
|
||||
]),
|
||||
dmc.Container(
|
||||
[
|
||||
html.B(title.title()),
|
||||
dcc.RadioItems(
|
||||
options=[text.replace('_', ' ') for text in options],
|
||||
id=id_dict,
|
||||
),
|
||||
],
|
||||
),
|
||||
)
|
||||
|
||||
labels_element = dmc.Grid(
|
||||
|
||||
Reference in New Issue
Block a user