Skip to content

Commit ac318ff

Browse files
guidooswaldDBclaude
andcommitted
Add About modal with GitHub repo link and contact email
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 99a38fb commit ac318ff

3 files changed

Lines changed: 69 additions & 3 deletions

File tree

app.py

Lines changed: 53 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -679,14 +679,53 @@ def build_sidebar() -> html.Div:
679679
]),
680680
], id="deploy-modal", is_open=False, size="lg", centered=True, className="deploy-modal")
681681

682+
_ABOUT_MODAL = dbc.Modal([
683+
dbc.ModalHeader(dbc.ModalTitle([
684+
html.Img(src="/assets/databricks.svg", style={"height": "24px"}, className="me-2"),
685+
"Databricks API Explorer",
686+
])),
687+
dbc.ModalBody([
688+
html.P([
689+
"An interactive REST API explorer for Databricks workspaces. "
690+
"Browse, execute, and inspect API calls across 15 categories and 45+ endpoints."
691+
], className="mb-3"),
692+
693+
html.Div([
694+
html.Div([
695+
html.I(className="bi bi-github me-2"),
696+
html.A(
697+
"github.com/guido-oswald_data/DatabricksAPIexplorer",
698+
href="https://github.com/guido-oswald_data/DatabricksAPIexplorer",
699+
target="_blank", rel="noopener noreferrer",
700+
className="about-link",
701+
),
702+
], className="about-row mb-2"),
703+
html.Div([
704+
html.I(className="bi bi-envelope me-2"),
705+
html.A(
706+
"guido@databricks.com",
707+
href="mailto:guido@databricks.com",
708+
className="about-link",
709+
),
710+
], className="about-row mb-2"),
711+
]),
712+
713+
html.Hr(className="divider"),
714+
html.Div([
715+
html.Span(VERSION, className="version-badge me-2"),
716+
html.Span("Built with Dash + Databricks SDK", className="text-muted small"),
717+
], className="d-flex align-items-center"),
718+
]),
719+
], id="about-modal", is_open=False, centered=True, className="deploy-modal")
720+
682721
TOPBAR = dbc.Navbar(
683722
dbc.Container([
684723
html.Div([
685-
html.A([
724+
html.Button([
686725
html.Img(src="/assets/databricks.svg", className="brand-logo me-2"),
687726
html.Span("Databricks", className="brand-db"),
688727
html.Span(" API Explorer", className="brand-rest"),
689-
], href="/", className="navbar-brand d-flex align-items-center text-decoration-none"),
728+
], id="about-btn", n_clicks=0, className="navbar-brand d-flex align-items-center text-decoration-none about-brand-btn"),
690729
html.Span(id="topbar-spinner", className="topbar-spinner topbar-spinner-hidden"),
691730
], className="d-flex align-items-center"),
692731
html.Div([
@@ -875,6 +914,7 @@ def _custom_section():
875914
_DROPDOWN_OVERLAY,
876915
USER_DROPDOWN, # fixed dropdown, outside normal flow
877916
_DEPLOY_MODAL,
917+
_ABOUT_MODAL,
878918

879919
html.Div([
880920
build_sidebar(),
@@ -942,6 +982,17 @@ def toggle_deploy_modal(n, is_open):
942982
return not is_open
943983

944984

985+
# 1c. Toggle about modal
986+
@app.callback(
987+
Output("about-modal", "is_open"),
988+
Input("about-btn", "n_clicks"),
989+
State("about-modal", "is_open"),
990+
prevent_initial_call=True,
991+
)
992+
def toggle_about_modal(n, is_open):
993+
return not is_open
994+
995+
945996
# 2. Toggle dropdown open/close — clientside for instant reactivity
946997
app.clientside_callback(
947998
"""

assets/style.css

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -726,6 +726,21 @@ body {
726726
transition: filter 0.15s;
727727
}
728728
.mode-badge-btn:hover { filter: brightness(1.3); }
729+
.about-brand-btn {
730+
background: none !important;
731+
border: none !important;
732+
padding: 0 !important;
733+
cursor: pointer;
734+
transition: opacity 0.15s;
735+
}
736+
.about-brand-btn:hover { opacity: 0.8; }
737+
.about-row { font-size: 14px; display: flex; align-items: center; }
738+
.about-link {
739+
color: var(--accent-primary, #7f4bc4);
740+
text-decoration: none;
741+
transition: color 0.15s;
742+
}
743+
.about-link:hover { color: #a77de8; text-decoration: underline; }
729744

730745
/* ── Deploy Modal ────────────────────────────────────────────────── */
731746
.deploy-modal .modal-content {

version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
268
1+
272

0 commit comments

Comments
 (0)