From d8cb2cbbf680feed3e6ac21c22809780d84b3ac9 Mon Sep 17 00:00:00 2001 From: Prad Nukala Date: Wed, 6 Nov 2024 13:32:51 -0500 Subject: [PATCH] feature/1126 implement pkl config (#1161) - **refactor: move marketing pages to** - **feat: add role select input** --- Taskfile.yml | 1 + devbox.lock | 76 ++-- internal/dwn/embed.go | 4 +- pkg/nebula/assets/css/styles.css | 362 ++++++++++++++++++ .../sections => auth}/authorize.templ | 4 +- .../sections => auth}/authorize_templ.go | 4 +- .../sections => auth}/login.templ | 4 +- .../sections => auth}/login_templ.go | 4 +- .../sections => auth}/register.templ | 4 +- .../sections => auth}/register_templ.go | 4 +- pkg/nebula/components/marketing/page.templ | 44 --- .../components/marketing/sections/cta.templ | 97 ----- .../marketing/sections/cta_templ.go | 67 ---- .../forms/consent_privacy.templ | 0 .../forms/consent_privacy_templ.go | 0 .../forms/credential_assert.templ | 0 .../forms/credential_assert_templ.go | 0 .../forms/credential_register.templ | 0 .../forms/credential_register_templ.go | 0 .../forms/details_basic.templ | 37 ++ .../forms/details_basic_templ.go | 45 ++- .../sections/utils.go => global/images.go} | 2 +- .../vaultindex/file.go => index.go} | 9 +- .../nav_footer.templ} | 2 +- .../nav_footer_templ.go} | 2 +- .../nav_header.templ} | 2 +- .../nav_header_templ.go} | 2 +- pkg/nebula/marketing/page.templ | 21 + .../{components => }/marketing/page_templ.go | 41 +- .../section_arch.templ} | 17 +- .../section_arch_templ.go} | 51 +-- pkg/nebula/marketing/section_cta.templ | 91 +++++ pkg/nebula/marketing/section_cta_templ.go | 67 ++++ .../section_hero.templ} | 2 +- .../section_hero_templ.go} | 24 +- .../section_highlights.templ} | 2 +- .../section_highlights_templ.go} | 26 +- .../section_lowlights.templ} | 27 +- .../section_lowlights_templ.go} | 33 +- .../section_mission.templ} | 2 +- .../section_mission_templ.go} | 20 +- .../authentication.templ} | 11 +- .../authentication_templ.go} | 10 +- .../marketing => }/modals/intro_video.templ | 0 .../modals/intro_video_templ.go | 0 .../route.go => routes/auth.go} | 12 +- pkg/nebula/routes/home.go | 22 ++ pkg/nebula/tailwind.config.js | 1 + .../view.templ => views/current.templ} | 2 +- .../view_templ.go => views/current_templ.go} | 2 +- .../vaultindex => views}/index.templ | 4 +- .../vaultindex => views}/index_templ.go | 4 +- pkg/workers/routes/gateway.go | 9 +- pkg/workers/routes/webnode.go | 8 +- 54 files changed, 854 insertions(+), 431 deletions(-) rename pkg/nebula/{components/authentication/sections => auth}/authorize.templ (91%) rename pkg/nebula/{components/authentication/sections => auth}/authorize_templ.go (96%) rename pkg/nebula/{components/authentication/sections => auth}/login.templ (90%) rename pkg/nebula/{components/authentication/sections => auth}/login_templ.go (96%) rename pkg/nebula/{components/authentication/sections => auth}/register.templ (89%) rename pkg/nebula/{components/authentication/sections => auth}/register_templ.go (97%) delete mode 100644 pkg/nebula/components/marketing/page.templ delete mode 100644 pkg/nebula/components/marketing/sections/cta.templ delete mode 100644 pkg/nebula/components/marketing/sections/cta_templ.go rename pkg/nebula/{components/authentication => }/forms/consent_privacy.templ (100%) rename pkg/nebula/{components/authentication => }/forms/consent_privacy_templ.go (100%) rename pkg/nebula/{components/authentication => }/forms/credential_assert.templ (100%) rename pkg/nebula/{components/authentication => }/forms/credential_assert_templ.go (100%) rename pkg/nebula/{components/authentication => }/forms/credential_register.templ (100%) rename pkg/nebula/{components/authentication => }/forms/credential_register_templ.go (100%) rename pkg/nebula/{components/authentication => }/forms/details_basic.templ (51%) rename pkg/nebula/{components/authentication => }/forms/details_basic_templ.go (67%) rename pkg/nebula/{components/marketing/sections/utils.go => global/images.go} (99%) rename pkg/nebula/{components/vaultindex/file.go => index.go} (50%) rename pkg/nebula/{components/marketing/sections/footer.templ => marketing/nav_footer.templ} (99%) rename pkg/nebula/{components/marketing/sections/footer_templ.go => marketing/nav_footer_templ.go} (99%) rename pkg/nebula/{components/marketing/sections/header.templ => marketing/nav_header.templ} (98%) rename pkg/nebula/{components/marketing/sections/header_templ.go => marketing/nav_header_templ.go} (99%) create mode 100644 pkg/nebula/marketing/page.templ rename pkg/nebula/{components => }/marketing/page_templ.go (67%) rename pkg/nebula/{components/marketing/sections/architecture.templ => marketing/section_arch.templ} (96%) rename pkg/nebula/{components/marketing/sections/architecture_templ.go => marketing/section_arch_templ.go} (87%) create mode 100644 pkg/nebula/marketing/section_cta.templ create mode 100644 pkg/nebula/marketing/section_cta_templ.go rename pkg/nebula/{components/marketing/sections/hero.templ => marketing/section_hero.templ} (99%) rename pkg/nebula/{components/marketing/sections/hero_templ.go => marketing/section_hero_templ.go} (93%) rename pkg/nebula/{components/marketing/sections/highlights.templ => marketing/section_highlights.templ} (99%) rename pkg/nebula/{components/marketing/sections/highlights_templ.go => marketing/section_highlights_templ.go} (90%) rename pkg/nebula/{components/marketing/sections/lowlights.templ => marketing/section_lowlights.templ} (90%) rename pkg/nebula/{components/marketing/sections/lowlights_templ.go => marketing/section_lowlights_templ.go} (90%) rename pkg/nebula/{components/marketing/sections/mission.templ => marketing/section_mission.templ} (99%) rename pkg/nebula/{components/marketing/sections/mission_templ.go => marketing/section_mission_templ.go} (94%) rename pkg/nebula/{components/authentication/modal.templ => modals/authentication.templ} (79%) rename pkg/nebula/{components/authentication/modal_templ.go => modals/authentication_templ.go} (95%) rename pkg/nebula/{components/marketing => }/modals/intro_video.templ (100%) rename pkg/nebula/{components/marketing => }/modals/intro_video_templ.go (100%) rename pkg/nebula/{components/authentication/route.go => routes/auth.go} (83%) create mode 100644 pkg/nebula/routes/home.go rename pkg/nebula/{components/authentication/view.templ => views/current.templ} (95%) rename pkg/nebula/{components/authentication/view_templ.go => views/current_templ.go} (98%) rename pkg/nebula/{components/vaultindex => views}/index.templ (95%) rename pkg/nebula/{components/vaultindex => views}/index_templ.go (98%) diff --git a/Taskfile.yml b/Taskfile.yml index 5e35fed6b..b46e78fd6 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -22,6 +22,7 @@ tasks: hway:deploy: dir: cmd/hway cmds: + - task: nebula:build - bunx wrangler deploy motr:build: diff --git a/devbox.lock b/devbox.lock index 19ddfab17..3f0c4c18e 100644 --- a/devbox.lock +++ b/devbox.lock @@ -2,98 +2,98 @@ "lockfile_version": "1", "packages": { "bun@latest": { - "last_modified": "2024-09-20T22:35:44Z", - "resolved": "github:NixOS/nixpkgs/a1d92660c6b3b7c26fb883500a80ea9d33321be2#bun", + "last_modified": "2024-10-23T04:36:58Z", + "resolved": "github:NixOS/nixpkgs/dfffb2e7a52d29a0ef8e21ec8a0f30487b227f1a#bun", "source": "devbox-search", - "version": "1.1.29", + "version": "1.1.31", "systems": { "aarch64-darwin": { "outputs": [ { "name": "out", - "path": "/nix/store/1hn8dddmy3l99x502d0fqz901gfk74px-bun-1.1.29", + "path": "/nix/store/yw0z6rg88lx3mk3990a8hv1p9n81c5rs-bun-1.1.31", "default": true } ], - "store_path": "/nix/store/1hn8dddmy3l99x502d0fqz901gfk74px-bun-1.1.29" + "store_path": "/nix/store/yw0z6rg88lx3mk3990a8hv1p9n81c5rs-bun-1.1.31" }, "aarch64-linux": { "outputs": [ { "name": "out", - "path": "/nix/store/q1k3hsk9hwsg6xllgd25pb0lrh51ym7z-bun-1.1.29", + "path": "/nix/store/00n6cawnzgxmih6vrkp7sg269njdlqfv-bun-1.1.31", "default": true } ], - "store_path": "/nix/store/q1k3hsk9hwsg6xllgd25pb0lrh51ym7z-bun-1.1.29" + "store_path": "/nix/store/00n6cawnzgxmih6vrkp7sg269njdlqfv-bun-1.1.31" }, "x86_64-darwin": { "outputs": [ { "name": "out", - "path": "/nix/store/0wi8b58g19k1gpvniyvax2hpb77sp0w6-bun-1.1.29", + "path": "/nix/store/4wg235mszvs98csdbk66lgdm6l9mzmnq-bun-1.1.31", "default": true } ], - "store_path": "/nix/store/0wi8b58g19k1gpvniyvax2hpb77sp0w6-bun-1.1.29" + "store_path": "/nix/store/4wg235mszvs98csdbk66lgdm6l9mzmnq-bun-1.1.31" }, "x86_64-linux": { "outputs": [ { "name": "out", - "path": "/nix/store/mqzlk40bnhx54by2m4lyyc02syippzad-bun-1.1.29", + "path": "/nix/store/hilx2jwdslc05d38q4fzpsli6pgc56sa-bun-1.1.31", "default": true } ], - "store_path": "/nix/store/mqzlk40bnhx54by2m4lyyc02syippzad-bun-1.1.29" + "store_path": "/nix/store/hilx2jwdslc05d38q4fzpsli6pgc56sa-bun-1.1.31" } } }, "go@1.22": { - "last_modified": "2024-09-12T11:58:09Z", - "resolved": "github:NixOS/nixpkgs/280db3decab4cbeb22a4599bd472229ab74d25e1#go", + "last_modified": "2024-10-13T23:44:06Z", + "resolved": "github:NixOS/nixpkgs/d4f247e89f6e10120f911e2e2d2254a050d0f732#go_1_22", "source": "devbox-search", - "version": "1.22.7", + "version": "1.22.8", "systems": { "aarch64-darwin": { "outputs": [ { "name": "out", - "path": "/nix/store/rfcwglhhspqx5v5h0sl4b3py14i6vpxa-go-1.22.7", + "path": "/nix/store/8mll7mf53m2hx3hx158gcls70ngcmhxi-go-1.22.8", "default": true } ], - "store_path": "/nix/store/rfcwglhhspqx5v5h0sl4b3py14i6vpxa-go-1.22.7" + "store_path": "/nix/store/8mll7mf53m2hx3hx158gcls70ngcmhxi-go-1.22.8" }, "aarch64-linux": { "outputs": [ { "name": "out", - "path": "/nix/store/64z59pb0ss407rbv1fcvq0ynngrwfa6k-go-1.22.7", + "path": "/nix/store/20v33h47dgf8h7baxh81d3dzdfbgxw33-go-1.22.8", "default": true } ], - "store_path": "/nix/store/64z59pb0ss407rbv1fcvq0ynngrwfa6k-go-1.22.7" + "store_path": "/nix/store/20v33h47dgf8h7baxh81d3dzdfbgxw33-go-1.22.8" }, "x86_64-darwin": { "outputs": [ { "name": "out", - "path": "/nix/store/r8199g59rmp6ac0lnx86fpk57fbxc3bk-go-1.22.7", + "path": "/nix/store/dzrq6b65b9wvd6xjrn0qy7prx2s6pnym-go-1.22.8", "default": true } ], - "store_path": "/nix/store/r8199g59rmp6ac0lnx86fpk57fbxc3bk-go-1.22.7" + "store_path": "/nix/store/dzrq6b65b9wvd6xjrn0qy7prx2s6pnym-go-1.22.8" }, "x86_64-linux": { "outputs": [ { "name": "out", - "path": "/nix/store/chzgk756zb2cqlzbjr86m0lfxi63cdfy-go-1.22.7", + "path": "/nix/store/gh9fsnl6gxrfzkrxwykbrp9lhnirmv9h-go-1.22.8", "default": true } ], - "store_path": "/nix/store/chzgk756zb2cqlzbjr86m0lfxi63cdfy-go-1.22.7" + "store_path": "/nix/store/gh9fsnl6gxrfzkrxwykbrp9lhnirmv9h-go-1.22.8" } } }, @@ -101,11 +101,21 @@ "last_modified": "2023-02-24T09:01:09Z", "resolved": "github:NixOS/nixpkgs/7d0ed7f2e5aea07ab22ccb338d27fbe347ed2f11#ipfs", "source": "devbox-search", - "version": "0.17.0" + "version": "0.17.0", + "systems": { + "aarch64-darwin": { + "outputs": [ + { + "path": "/nix/store/1azparhiwjzxgpkswpqnapzw0bfb7vl7-kubo-0.17.0", + "default": true + } + ] + } + } }, "templ@latest": { - "last_modified": "2024-09-10T15:01:03Z", - "resolved": "github:NixOS/nixpkgs/5ed627539ac84809c78b2dd6d26a5cebeb5ae269#templ", + "last_modified": "2024-10-13T23:44:06Z", + "resolved": "github:NixOS/nixpkgs/d4f247e89f6e10120f911e2e2d2254a050d0f732#templ", "source": "devbox-search", "version": "0.2.778", "systems": { @@ -113,41 +123,41 @@ "outputs": [ { "name": "out", - "path": "/nix/store/n3yqslisz9v81k4w4vhci1v2bl1sqf9s-templ-0.2.778", + "path": "/nix/store/n7bmbwk126kiclzi317yprpnc6rkn0jv-templ-0.2.778", "default": true } ], - "store_path": "/nix/store/n3yqslisz9v81k4w4vhci1v2bl1sqf9s-templ-0.2.778" + "store_path": "/nix/store/n7bmbwk126kiclzi317yprpnc6rkn0jv-templ-0.2.778" }, "aarch64-linux": { "outputs": [ { "name": "out", - "path": "/nix/store/i4xjiw0vc25qpr3g01q0x401351w28hr-templ-0.2.778", + "path": "/nix/store/9fi535j2qw60x28vb5wlcz989z2wz959-templ-0.2.778", "default": true } ], - "store_path": "/nix/store/i4xjiw0vc25qpr3g01q0x401351w28hr-templ-0.2.778" + "store_path": "/nix/store/9fi535j2qw60x28vb5wlcz989z2wz959-templ-0.2.778" }, "x86_64-darwin": { "outputs": [ { "name": "out", - "path": "/nix/store/77w522agb5fgsr36jkifcccr9x4xwkf9-templ-0.2.778", + "path": "/nix/store/6r17bj68ahbf41xlk87pilbhj394anyy-templ-0.2.778", "default": true } ], - "store_path": "/nix/store/77w522agb5fgsr36jkifcccr9x4xwkf9-templ-0.2.778" + "store_path": "/nix/store/6r17bj68ahbf41xlk87pilbhj394anyy-templ-0.2.778" }, "x86_64-linux": { "outputs": [ { "name": "out", - "path": "/nix/store/1g5ji5930j03cycpcjy12z6lr24l9c65-templ-0.2.778", + "path": "/nix/store/6c1sqrhl7a68npksq7jicsa310qj9k1q-templ-0.2.778", "default": true } ], - "store_path": "/nix/store/1g5ji5930j03cycpcjy12z6lr24l9c65-templ-0.2.778" + "store_path": "/nix/store/6c1sqrhl7a68npksq7jicsa310qj9k1q-templ-0.2.778" } } } diff --git a/internal/dwn/embed.go b/internal/dwn/embed.go index 9860a04f9..c56183bbd 100644 --- a/internal/dwn/embed.go +++ b/internal/dwn/embed.go @@ -6,7 +6,7 @@ import ( "github.com/ipfs/boxo/files" "github.com/onsonr/sonr/internal/dwn/gen" - "github.com/onsonr/sonr/pkg/nebula/components/vaultindex" + "github.com/onsonr/sonr/pkg/nebula" ) const ( @@ -24,7 +24,7 @@ var swJSData []byte // NewVaultDirectory creates a new directory with the default files func NewVaultDirectory(cnfg *gen.Config) (files.Node, error) { - idxFile, err := vaultindex.BuildFile(cnfg) + idxFile, err := nebula.BuildVaultFile(cnfg) if err != nil { return nil, err } diff --git a/pkg/nebula/assets/css/styles.css b/pkg/nebula/assets/css/styles.css index a91aa9348..03ffcb50a 100644 --- a/pkg/nebula/assets/css/styles.css +++ b/pkg/nebula/assets/css/styles.css @@ -957,6 +957,186 @@ select{ } } +.form-input,.form-textarea,.form-select,.form-multiselect{ + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; + background-color: #fff; + border-color: #6b7280; + border-width: 1px; + border-radius: 0px; + padding-top: 0.5rem; + padding-right: 0.75rem; + padding-bottom: 0.5rem; + padding-left: 0.75rem; + font-size: 1rem; + line-height: 1.5rem; + --tw-shadow: 0 0 #0000; +} + +.form-input:focus, .form-textarea:focus, .form-select:focus, .form-multiselect:focus{ + outline: 2px solid transparent; + outline-offset: 2px; + --tw-ring-inset: var(--tw-empty,/*!*/ /*!*/); + --tw-ring-offset-width: 0px; + --tw-ring-offset-color: #fff; + --tw-ring-color: #2563eb; + --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); + --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color); + box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow); + border-color: #2563eb; +} + +.form-input::-moz-placeholder, .form-textarea::-moz-placeholder{ + color: #6b7280; + opacity: 1; +} + +.form-input::placeholder,.form-textarea::placeholder{ + color: #6b7280; + opacity: 1; +} + +.form-input::-webkit-datetime-edit-fields-wrapper{ + padding: 0; +} + +.form-input::-webkit-date-and-time-value{ + min-height: 1.5em; + text-align: inherit; +} + +.form-input::-webkit-datetime-edit{ + display: inline-flex; +} + +.form-input::-webkit-datetime-edit,.form-input::-webkit-datetime-edit-year-field,.form-input::-webkit-datetime-edit-month-field,.form-input::-webkit-datetime-edit-day-field,.form-input::-webkit-datetime-edit-hour-field,.form-input::-webkit-datetime-edit-minute-field,.form-input::-webkit-datetime-edit-second-field,.form-input::-webkit-datetime-edit-millisecond-field,.form-input::-webkit-datetime-edit-meridiem-field{ + padding-top: 0; + padding-bottom: 0; +} + +.form-select{ + background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); + background-position: right 0.5rem center; + background-repeat: no-repeat; + background-size: 1.5em 1.5em; + padding-right: 2.5rem; + -webkit-print-color-adjust: exact; + print-color-adjust: exact; +} + +.form-select:where([size]:not([size="1"])){ + background-image: initial; + background-position: initial; + background-repeat: unset; + background-size: initial; + padding-right: 0.75rem; + -webkit-print-color-adjust: unset; + print-color-adjust: unset; +} + +.form-checkbox,.form-radio{ + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; + padding: 0; + -webkit-print-color-adjust: exact; + print-color-adjust: exact; + display: inline-block; + vertical-align: middle; + background-origin: border-box; + -webkit-user-select: none; + -moz-user-select: none; + user-select: none; + flex-shrink: 0; + height: 1rem; + width: 1rem; + color: #2563eb; + background-color: #fff; + border-color: #6b7280; + border-width: 1px; + --tw-shadow: 0 0 #0000; +} + +.form-checkbox{ + border-radius: 0px; +} + +.form-radio{ + border-radius: 100%; +} + +.form-checkbox:focus,.form-radio:focus{ + outline: 2px solid transparent; + outline-offset: 2px; + --tw-ring-inset: var(--tw-empty,/*!*/ /*!*/); + --tw-ring-offset-width: 2px; + --tw-ring-offset-color: #fff; + --tw-ring-color: #2563eb; + --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); + --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color); + box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow); +} + +.form-checkbox:checked,.form-radio:checked{ + border-color: transparent; + background-color: currentColor; + background-size: 100% 100%; + background-position: center; + background-repeat: no-repeat; +} + +.form-checkbox:checked{ + background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e"); +} + +@media (forced-colors: active) { + .form-checkbox:checked{ + -webkit-appearance: auto; + -moz-appearance: auto; + appearance: auto; + } +} + +.form-radio:checked{ + background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e"); +} + +@media (forced-colors: active) { + .form-radio:checked{ + -webkit-appearance: auto; + -moz-appearance: auto; + appearance: auto; + } +} + +.form-checkbox:checked:hover,.form-checkbox:checked:focus,.form-radio:checked:hover,.form-radio:checked:focus{ + border-color: transparent; + background-color: currentColor; +} + +.form-checkbox:indeterminate{ + background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3e%3c/svg%3e"); + border-color: transparent; + background-color: currentColor; + background-size: 100% 100%; + background-position: center; + background-repeat: no-repeat; +} + +@media (forced-colors: active) { + .form-checkbox:indeterminate{ + -webkit-appearance: auto; + -moz-appearance: auto; + appearance: auto; + } +} + +.form-checkbox:indeterminate:hover,.form-checkbox:indeterminate:focus{ + border-color: transparent; + background-color: currentColor; +} + .motion-preset-slide-up{ --motion-origin-translate-y: 25%; --motion-origin-opacity: 0; @@ -1187,6 +1367,10 @@ select{ margin-right: 1.75rem; } +.mt-0{ + margin-top: 0px; +} + .mt-0\.5{ margin-top: 0.125rem; } @@ -1219,6 +1403,10 @@ select{ margin-top: 1.5rem; } +.mt-8{ + margin-top: 2rem; +} + .box-content{ box-sizing: content-box; } @@ -1575,6 +1763,11 @@ select{ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +.translate-y-px{ + --tw-translate-y: 1px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} + .rotate-1{ --tw-rotate: 1deg; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); @@ -1650,6 +1843,10 @@ select{ appearance: none; } +.grid-cols-1{ + grid-template-columns: repeat(1, minmax(0, 1fr)); +} + .grid-cols-2{ grid-template-columns: repeat(2, minmax(0, 1fr)); } @@ -1714,6 +1911,10 @@ select{ gap: 1rem; } +.gap-6{ + gap: 1.5rem; +} + .gap-8{ gap: 2rem; } @@ -1769,6 +1970,12 @@ select{ margin-bottom: calc(0.5rem * var(--tw-space-y-reverse)); } +.space-y-3 > :not([hidden]) ~ :not([hidden]){ + --tw-space-y-reverse: 0; + margin-top: calc(0.75rem * calc(1 - var(--tw-space-y-reverse))); + margin-bottom: calc(0.75rem * var(--tw-space-y-reverse)); +} + .space-y-4 > :not([hidden]) ~ :not([hidden]){ --tw-space-y-reverse: 0; margin-top: calc(1rem * calc(1 - var(--tw-space-y-reverse))); @@ -1781,6 +1988,12 @@ select{ margin-bottom: calc(1.5rem * var(--tw-space-y-reverse)); } +.divide-y > :not([hidden]) ~ :not([hidden]){ + --tw-divide-y-reverse: 0; + border-top-width: calc(1px * calc(1 - var(--tw-divide-y-reverse))); + border-bottom-width: calc(1px * var(--tw-divide-y-reverse)); +} + .overflow-hidden{ overflow: hidden; } @@ -1814,10 +2027,18 @@ select{ border-width: 1px; } +.border-0{ + border-width: 0px; +} + .border-2{ border-width: 2px; } +.border-b-2{ + border-bottom-width: 2px; +} + .border-t{ border-top-width: 1px; } @@ -1827,6 +2048,16 @@ select{ border-color: rgb(37 99 235 / var(--tw-border-opacity)); } +.border-gray-200{ + --tw-border-opacity: 1; + border-color: rgb(229 231 235 / var(--tw-border-opacity)); +} + +.border-gray-300{ + --tw-border-opacity: 1; + border-color: rgb(209 213 219 / var(--tw-border-opacity)); +} + .border-green-600{ --tw-border-opacity: 1; border-color: rgb(22 163 74 / var(--tw-border-opacity)); @@ -1899,6 +2130,16 @@ select{ background-color: rgb(37 99 235 / var(--tw-bg-opacity)); } +.bg-gray-100{ + --tw-bg-opacity: 1; + background-color: rgb(243 244 246 / var(--tw-bg-opacity)); +} + +.bg-gray-200{ + --tw-bg-opacity: 1; + background-color: rgb(229 231 235 / var(--tw-bg-opacity)); +} + .bg-green-50{ --tw-bg-opacity: 1; background-color: rgb(240 253 244 / var(--tw-bg-opacity)); @@ -2089,6 +2330,11 @@ select{ padding: 1.75rem; } +.px-0\.5{ + padding-left: 0.125rem; + padding-right: 0.125rem; +} + .px-2\.5{ padding-left: 0.625rem; padding-right: 0.625rem; @@ -2340,6 +2586,11 @@ select{ letter-spacing: 0.025em; } +.text-black{ + --tw-text-opacity: 1; + color: rgb(0 0 0 / var(--tw-text-opacity)); +} + .text-blue-500{ --tw-text-opacity: 1; color: rgb(59 130 246 / var(--tw-text-opacity)); @@ -2369,6 +2620,16 @@ select{ color: rgb(75 85 99 / var(--tw-text-opacity)); } +.text-gray-700{ + --tw-text-opacity: 1; + color: rgb(55 65 81 / var(--tw-text-opacity)); +} + +.text-gray-900{ + --tw-text-opacity: 1; + color: rgb(17 24 39 / var(--tw-text-opacity)); +} + .text-green-500{ --tw-text-opacity: 1; color: rgb(34 197 94 / var(--tw-text-opacity)); @@ -2379,6 +2640,11 @@ select{ color: rgb(22 163 74 / var(--tw-text-opacity)); } +.text-indigo-600{ + --tw-text-opacity: 1; + color: rgb(79 70 229 / var(--tw-text-opacity)); +} + .text-neutral-100{ --tw-text-opacity: 1; color: rgb(245 245 245 / var(--tw-text-opacity)); @@ -2463,6 +2729,10 @@ select{ color: rgb(24 24 27 / var(--tw-text-opacity)); } +.underline{ + text-decoration-line: underline; +} + .antialiased{ -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; @@ -2480,6 +2750,10 @@ select{ opacity: 0.2; } +.opacity-50{ + opacity: 0.5; +} + .opacity-60{ opacity: 0.6; } @@ -3226,6 +3500,11 @@ input[type="search"]::-webkit-search-results-decoration { background-color: rgb(29 78 216 / var(--tw-bg-opacity)); } +.hover\:bg-gray-50:hover{ + --tw-bg-opacity: 1; + background-color: rgb(249 250 251 / var(--tw-bg-opacity)); +} + .hover\:bg-green-100:hover{ --tw-bg-opacity: 1; background-color: rgb(220 252 231 / var(--tw-bg-opacity)); @@ -3359,11 +3638,40 @@ input[type="search"]::-webkit-search-results-decoration { opacity: 1; } +.focus\:border-black:focus{ + --tw-border-opacity: 1; + border-color: rgb(0 0 0 / var(--tw-border-opacity)); +} + +.focus\:border-gray-300:focus{ + --tw-border-opacity: 1; + border-color: rgb(209 213 219 / var(--tw-border-opacity)); +} + +.focus\:border-gray-500:focus{ + --tw-border-opacity: 1; + border-color: rgb(107 114 128 / var(--tw-border-opacity)); +} + +.focus\:border-indigo-300:focus{ + --tw-border-opacity: 1; + border-color: rgb(165 180 252 / var(--tw-border-opacity)); +} + +.focus\:border-transparent:focus{ + border-color: transparent; +} + .focus\:border-zinc-300:focus{ --tw-border-opacity: 1; border-color: rgb(212 212 216 / var(--tw-border-opacity)); } +.focus\:bg-gray-200:focus{ + --tw-bg-opacity: 1; + background-color: rgb(229 231 235 / var(--tw-bg-opacity)); +} + .focus\:bg-white:focus{ --tw-bg-opacity: 1; background-color: rgb(255 255 255 / var(--tw-bg-opacity)); @@ -3374,12 +3682,35 @@ input[type="search"]::-webkit-search-results-decoration { outline-offset: 2px; } +.focus\:ring:focus{ + --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); + --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color); + box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); +} + +.focus\:ring-0:focus{ + --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); + --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color); + box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); +} + +.focus\:ring-1:focus{ + --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); + --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color); + box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); +} + .focus\:ring-2:focus{ --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color); box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); } +.focus\:ring-black:focus{ + --tw-ring-opacity: 1; + --tw-ring-color: rgb(0 0 0 / var(--tw-ring-opacity)); +} + .focus\:ring-blue-100:focus{ --tw-ring-opacity: 1; --tw-ring-color: rgb(219 234 254 / var(--tw-ring-opacity)); @@ -3390,6 +3721,16 @@ input[type="search"]::-webkit-search-results-decoration { --tw-ring-color: rgb(29 78 216 / var(--tw-ring-opacity)); } +.focus\:ring-gray-500:focus{ + --tw-ring-opacity: 1; + --tw-ring-color: rgb(107 114 128 / var(--tw-ring-opacity)); +} + +.focus\:ring-gray-700:focus{ + --tw-ring-opacity: 1; + --tw-ring-color: rgb(55 65 81 / var(--tw-ring-opacity)); +} + .focus\:ring-green-100:focus{ --tw-ring-opacity: 1; --tw-ring-color: rgb(220 252 231 / var(--tw-ring-opacity)); @@ -3400,6 +3741,11 @@ input[type="search"]::-webkit-search-results-decoration { --tw-ring-color: rgb(21 128 61 / var(--tw-ring-opacity)); } +.focus\:ring-indigo-200:focus{ + --tw-ring-opacity: 1; + --tw-ring-color: rgb(199 210 254 / var(--tw-ring-opacity)); +} + .focus\:ring-neutral-100:focus{ --tw-ring-opacity: 1; --tw-ring-color: rgb(245 245 245 / var(--tw-ring-opacity)); @@ -3439,6 +3785,14 @@ input[type="search"]::-webkit-search-results-decoration { --tw-ring-color: rgb(161 98 7 / var(--tw-ring-opacity)); } +.focus\:ring-opacity-50:focus{ + --tw-ring-opacity: 0.5; +} + +.focus\:ring-offset-0:focus{ + --tw-ring-offset-width: 0px; +} + .focus\:ring-offset-2:focus{ --tw-ring-offset-width: 2px; } @@ -3633,10 +3987,18 @@ input[type="search"]::-webkit-search-results-decoration { margin-bottom: 0px; } + .md\:max-w-4xl{ + max-width: 56rem; + } + .md\:max-w-none{ max-width: none; } + .md\:grid-cols-2{ + grid-template-columns: repeat(2, minmax(0, 1fr)); + } + .md\:grid-cols-3{ grid-template-columns: repeat(3, minmax(0, 1fr)); } diff --git a/pkg/nebula/components/authentication/sections/authorize.templ b/pkg/nebula/auth/authorize.templ similarity index 91% rename from pkg/nebula/components/authentication/sections/authorize.templ rename to pkg/nebula/auth/authorize.templ index 8dd62d0b0..7e91043d1 100644 --- a/pkg/nebula/components/authentication/sections/authorize.templ +++ b/pkg/nebula/auth/authorize.templ @@ -1,7 +1,7 @@ -package sections +package auth import ( - "github.com/onsonr/sonr/pkg/nebula/components/authentication/forms" + "github.com/onsonr/sonr/pkg/nebula/forms" "github.com/onsonr/sonr/pkg/nebula/global/styles" "github.com/onsonr/sonr/pkg/nebula/global/ui" ) diff --git a/pkg/nebula/components/authentication/sections/authorize_templ.go b/pkg/nebula/auth/authorize_templ.go similarity index 96% rename from pkg/nebula/components/authentication/sections/authorize_templ.go rename to pkg/nebula/auth/authorize_templ.go index 2187d334f..338f3e766 100644 --- a/pkg/nebula/components/authentication/sections/authorize_templ.go +++ b/pkg/nebula/auth/authorize_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package auth //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -9,7 +9,7 @@ import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" import ( - "github.com/onsonr/sonr/pkg/nebula/components/authentication/forms" + "github.com/onsonr/sonr/pkg/nebula/forms" "github.com/onsonr/sonr/pkg/nebula/global/styles" "github.com/onsonr/sonr/pkg/nebula/global/ui" ) diff --git a/pkg/nebula/components/authentication/sections/login.templ b/pkg/nebula/auth/login.templ similarity index 90% rename from pkg/nebula/components/authentication/sections/login.templ rename to pkg/nebula/auth/login.templ index 4fa8d39e0..83fde80b9 100644 --- a/pkg/nebula/components/authentication/sections/login.templ +++ b/pkg/nebula/auth/login.templ @@ -1,7 +1,7 @@ -package sections +package auth import ( - "github.com/onsonr/sonr/pkg/nebula/components/authentication/forms" + "github.com/onsonr/sonr/pkg/nebula/forms" "github.com/onsonr/sonr/pkg/nebula/global/styles" "github.com/onsonr/sonr/pkg/nebula/global/ui" ) diff --git a/pkg/nebula/components/authentication/sections/login_templ.go b/pkg/nebula/auth/login_templ.go similarity index 96% rename from pkg/nebula/components/authentication/sections/login_templ.go rename to pkg/nebula/auth/login_templ.go index 5b4f49fb3..9bd89e115 100644 --- a/pkg/nebula/components/authentication/sections/login_templ.go +++ b/pkg/nebula/auth/login_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package auth //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -9,7 +9,7 @@ import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" import ( - "github.com/onsonr/sonr/pkg/nebula/components/authentication/forms" + "github.com/onsonr/sonr/pkg/nebula/forms" "github.com/onsonr/sonr/pkg/nebula/global/styles" "github.com/onsonr/sonr/pkg/nebula/global/ui" ) diff --git a/pkg/nebula/components/authentication/sections/register.templ b/pkg/nebula/auth/register.templ similarity index 89% rename from pkg/nebula/components/authentication/sections/register.templ rename to pkg/nebula/auth/register.templ index 214551462..a44331489 100644 --- a/pkg/nebula/components/authentication/sections/register.templ +++ b/pkg/nebula/auth/register.templ @@ -1,6 +1,6 @@ -package sections +package auth -import "github.com/onsonr/sonr/pkg/nebula/components/authentication/forms" +import "github.com/onsonr/sonr/pkg/nebula/forms" templ RegisterStart() { @forms.BasicDetailsForm() diff --git a/pkg/nebula/components/authentication/sections/register_templ.go b/pkg/nebula/auth/register_templ.go similarity index 97% rename from pkg/nebula/components/authentication/sections/register_templ.go rename to pkg/nebula/auth/register_templ.go index 773f9c25d..d83307755 100644 --- a/pkg/nebula/components/authentication/sections/register_templ.go +++ b/pkg/nebula/auth/register_templ.go @@ -1,14 +1,14 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package auth //lint:file-ignore SA4006 This context is only used if a nested component is present. import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" -import "github.com/onsonr/sonr/pkg/nebula/components/authentication/forms" +import "github.com/onsonr/sonr/pkg/nebula/forms" func RegisterStart() templ.Component { return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { diff --git a/pkg/nebula/components/marketing/page.templ b/pkg/nebula/components/marketing/page.templ deleted file mode 100644 index 16a3052e1..000000000 --- a/pkg/nebula/components/marketing/page.templ +++ /dev/null @@ -1,44 +0,0 @@ -package marketing - -import ( - "github.com/labstack/echo/v4" - "github.com/onsonr/sonr/internal/ctx" - "github.com/onsonr/sonr/pkg/nebula/components/marketing/sections" - "github.com/onsonr/sonr/pkg/nebula/global/styles" - "log" -) - -// ╭───────────────────────────────────────────────────────────╮ -// │ Home Routes - Marketing │ -// ╰───────────────────────────────────────────────────────────╯ - -func HomeRoute(c echo.Context) error { - s, err := ctx.GetHWAYContext(c) - if err != nil { - return err - } - log.Printf("Session ID: %s", s.ID()) - return ctx.RenderTempl(c, View()) -} - -// ╭───────────────────────────────────────────────────────────╮ -// │ Static Content Values │ -// ╰───────────────────────────────────────────────────────────╯ - -// ╭─────────────────────────────────────────────────────────╮ -// │ Final Rendering │ -// ╰─────────────────────────────────────────────────────────╯ - -// View renders the home page -templ View() { - @styles.LayoutNoBody("Sonr.ID", true) { - @sections.Header() - @sections.Hero() - @sections.Highlights() - @sections.Mission() - @sections.Architecture() - @sections.Lowlights() - @sections.CallToAction() - @sections.Footer() - } -} diff --git a/pkg/nebula/components/marketing/sections/cta.templ b/pkg/nebula/components/marketing/sections/cta.templ deleted file mode 100644 index 7aa27160e..000000000 --- a/pkg/nebula/components/marketing/sections/cta.templ +++ /dev/null @@ -1,97 +0,0 @@ -package sections - -import models "github.com/onsonr/sonr/internal/orm/marketing" - -// ╭───────────────────────────────────────────────────────────╮ -// │ Data Model │ -// ╰───────────────────────────────────────────────────────────╯ - -var cta = &models.CallToAction{ - Logo: &models.Image{ - Src: "https://cdn.sonr.id/logo-zinc.svg", - Width: "60", - Height: "60", - }, - Heading: "Take control of your Identity", - Subtitle: "Sonr is a decentralized, permissionless, and censorship-resistant identity network.", - Primary: &models.Button{ - Href: "request-demo.html", - Text: "Register", - }, - Secondary: &models.Button{ - Href: "#0", - Text: "Learn More", - }, -} - -// ╭───────────────────────────────────────────────────────────╮ -// │ Render Section View │ -// ╰───────────────────────────────────────────────────────────╯ -templ CallToAction() { -
-
-
-
-
- - Logo - -
-

- Take control of your Identity - - today - - -

-

Sonr removes creative distances by connecting beginners, pros, and every team in between. Are you ready to start your journey?

-
-
- Register -
-
- Log in -
-
-
- -
-
    -
  • - - - -
  • -
  • - - - -
  • -
  • - - - -
  • -
  • - - - -
  • -
  • - - - -
  • -
  • - - - -
  • -
-
-
-
-
-} diff --git a/pkg/nebula/components/marketing/sections/cta_templ.go b/pkg/nebula/components/marketing/sections/cta_templ.go deleted file mode 100644 index d2e5974c4..000000000 --- a/pkg/nebula/components/marketing/sections/cta_templ.go +++ /dev/null @@ -1,67 +0,0 @@ -// Code generated by templ - DO NOT EDIT. - -// templ: version: v0.2.778 -package sections - -//lint:file-ignore SA4006 This context is only used if a nested component is present. - -import "github.com/a-h/templ" -import templruntime "github.com/a-h/templ/runtime" - -import models "github.com/onsonr/sonr/internal/orm/marketing" - -// ╭───────────────────────────────────────────────────────────╮ -// │ Data Model │ -// ╰───────────────────────────────────────────────────────────╯ - -var cta = &models.CallToAction{ - Logo: &models.Image{ - Src: "https://cdn.sonr.id/logo-zinc.svg", - Width: "60", - Height: "60", - }, - Heading: "Take control of your Identity", - Subtitle: "Sonr is a decentralized, permissionless, and censorship-resistant identity network.", - Primary: &models.Button{ - Href: "request-demo.html", - Text: "Register", - }, - Secondary: &models.Button{ - Href: "#0", - Text: "Learn More", - }, -} - -// ╭───────────────────────────────────────────────────────────╮ -// │ Render Section View │ -// ╰───────────────────────────────────────────────────────────╯ -func CallToAction() templ.Component { - return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { - templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context - if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { - return templ_7745c5c3_CtxErr - } - templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W) - if !templ_7745c5c3_IsBuffer { - defer func() { - templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer) - if templ_7745c5c3_Err == nil { - templ_7745c5c3_Err = templ_7745c5c3_BufErr - } - }() - } - ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Var1 := templ.GetChildren(ctx) - if templ_7745c5c3_Var1 == nil { - templ_7745c5c3_Var1 = templ.NopComponent - } - ctx = templ.ClearChildren(ctx) - _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("
\"Logo\"

Take control of your Identity today

Sonr removes creative distances by connecting beginners, pros, and every team in between. Are you ready to start your journey?

") - if templ_7745c5c3_Err != nil { - return templ_7745c5c3_Err - } - return templ_7745c5c3_Err - }) -} - -var _ = templruntime.GeneratedTemplate diff --git a/pkg/nebula/components/authentication/forms/consent_privacy.templ b/pkg/nebula/forms/consent_privacy.templ similarity index 100% rename from pkg/nebula/components/authentication/forms/consent_privacy.templ rename to pkg/nebula/forms/consent_privacy.templ diff --git a/pkg/nebula/components/authentication/forms/consent_privacy_templ.go b/pkg/nebula/forms/consent_privacy_templ.go similarity index 100% rename from pkg/nebula/components/authentication/forms/consent_privacy_templ.go rename to pkg/nebula/forms/consent_privacy_templ.go diff --git a/pkg/nebula/components/authentication/forms/credential_assert.templ b/pkg/nebula/forms/credential_assert.templ similarity index 100% rename from pkg/nebula/components/authentication/forms/credential_assert.templ rename to pkg/nebula/forms/credential_assert.templ diff --git a/pkg/nebula/components/authentication/forms/credential_assert_templ.go b/pkg/nebula/forms/credential_assert_templ.go similarity index 100% rename from pkg/nebula/components/authentication/forms/credential_assert_templ.go rename to pkg/nebula/forms/credential_assert_templ.go diff --git a/pkg/nebula/components/authentication/forms/credential_register.templ b/pkg/nebula/forms/credential_register.templ similarity index 100% rename from pkg/nebula/components/authentication/forms/credential_register.templ rename to pkg/nebula/forms/credential_register.templ diff --git a/pkg/nebula/components/authentication/forms/credential_register_templ.go b/pkg/nebula/forms/credential_register_templ.go similarity index 100% rename from pkg/nebula/components/authentication/forms/credential_register_templ.go rename to pkg/nebula/forms/credential_register_templ.go diff --git a/pkg/nebula/components/authentication/forms/details_basic.templ b/pkg/nebula/forms/details_basic.templ similarity index 51% rename from pkg/nebula/components/authentication/forms/details_basic.templ rename to pkg/nebula/forms/details_basic.templ index 03193f63e..47fc53747 100644 --- a/pkg/nebula/components/authentication/forms/details_basic.templ +++ b/pkg/nebula/forms/details_basic.templ @@ -3,12 +3,49 @@ package forms templ BasicDetailsForm() {
+ @roleSelectInput() @nameInput() @usernameInput()
} +templ roleSelectInput() { +
+ +
+} + templ nameInput() {
} diff --git a/pkg/nebula/components/authentication/forms/details_basic_templ.go b/pkg/nebula/forms/details_basic_templ.go similarity index 67% rename from pkg/nebula/components/authentication/forms/details_basic_templ.go rename to pkg/nebula/forms/details_basic_templ.go index 925f5a565..73da245c6 100644 --- a/pkg/nebula/components/authentication/forms/details_basic_templ.go +++ b/pkg/nebula/forms/details_basic_templ.go @@ -33,6 +33,10 @@ func BasicDetailsForm() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } + templ_7745c5c3_Err = roleSelectInput().Render(ctx, templ_7745c5c3_Buffer) + if templ_7745c5c3_Err != nil { + return templ_7745c5c3_Err + } templ_7745c5c3_Err = nameInput().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err @@ -49,6 +53,35 @@ func BasicDetailsForm() templ.Component { }) } +func roleSelectInput() templ.Component { + return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { + templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context + if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { + return templ_7745c5c3_CtxErr + } + templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W) + if !templ_7745c5c3_IsBuffer { + defer func() { + templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer) + if templ_7745c5c3_Err == nil { + templ_7745c5c3_Err = templ_7745c5c3_BufErr + } + }() + } + ctx = templ.InitializeContext(ctx) + templ_7745c5c3_Var2 := templ.GetChildren(ctx) + if templ_7745c5c3_Var2 == nil { + templ_7745c5c3_Var2 = templ.NopComponent + } + ctx = templ.ClearChildren(ctx) + _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("
") + if templ_7745c5c3_Err != nil { + return templ_7745c5c3_Err + } + return templ_7745c5c3_Err + }) +} + func nameInput() templ.Component { return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context @@ -65,9 +98,9 @@ func nameInput() templ.Component { }() } ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Var2 := templ.GetChildren(ctx) - if templ_7745c5c3_Var2 == nil { - templ_7745c5c3_Var2 = templ.NopComponent + templ_7745c5c3_Var3 := templ.GetChildren(ctx) + if templ_7745c5c3_Var3 == nil { + templ_7745c5c3_Var3 = templ.NopComponent } ctx = templ.ClearChildren(ctx) _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("
") @@ -94,9 +127,9 @@ func usernameInput() templ.Component { }() } ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Var3 := templ.GetChildren(ctx) - if templ_7745c5c3_Var3 == nil { - templ_7745c5c3_Var3 = templ.NopComponent + templ_7745c5c3_Var4 := templ.GetChildren(ctx) + if templ_7745c5c3_Var4 == nil { + templ_7745c5c3_Var4 = templ.NopComponent } ctx = templ.ClearChildren(ctx) _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("
") diff --git a/pkg/nebula/components/marketing/sections/utils.go b/pkg/nebula/global/images.go similarity index 99% rename from pkg/nebula/components/marketing/sections/utils.go rename to pkg/nebula/global/images.go index 5d091039a..847f20ede 100644 --- a/pkg/nebula/components/marketing/sections/utils.go +++ b/pkg/nebula/global/images.go @@ -1,4 +1,4 @@ -package sections +package global import "fmt" diff --git a/pkg/nebula/components/vaultindex/file.go b/pkg/nebula/index.go similarity index 50% rename from pkg/nebula/components/vaultindex/file.go rename to pkg/nebula/index.go index f3f831b7d..7bbebfad8 100644 --- a/pkg/nebula/components/vaultindex/file.go +++ b/pkg/nebula/index.go @@ -1,4 +1,4 @@ -package vaultindex +package nebula import ( "bytes" @@ -6,12 +6,13 @@ import ( "github.com/ipfs/boxo/files" "github.com/onsonr/sonr/internal/dwn/gen" + "github.com/onsonr/sonr/pkg/nebula/views" ) -// BuildFile builds the index.html file for the vault -func BuildFile(cnfg *gen.Config) (files.Node, error) { +// BuildVaultFile builds the index.html file for the vault +func BuildVaultFile(cnfg *gen.Config) (files.Node, error) { w := bytes.NewBuffer(nil) - err := IndexFile().Render(context.Background(), w) + err := views.VaultIndexFile().Render(context.Background(), w) if err != nil { return nil, err } diff --git a/pkg/nebula/components/marketing/sections/footer.templ b/pkg/nebula/marketing/nav_footer.templ similarity index 99% rename from pkg/nebula/components/marketing/sections/footer.templ rename to pkg/nebula/marketing/nav_footer.templ index 9afbb64c7..926bd0b83 100644 --- a/pkg/nebula/components/marketing/sections/footer.templ +++ b/pkg/nebula/marketing/nav_footer.templ @@ -1,4 +1,4 @@ -package sections +package marketing templ Footer() { diff --git a/pkg/nebula/components/marketing/sections/footer_templ.go b/pkg/nebula/marketing/nav_footer_templ.go similarity index 99% rename from pkg/nebula/components/marketing/sections/footer_templ.go rename to pkg/nebula/marketing/nav_footer_templ.go index 7dc321650..9545d0f6a 100644 --- a/pkg/nebula/components/marketing/sections/footer_templ.go +++ b/pkg/nebula/marketing/nav_footer_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. diff --git a/pkg/nebula/components/marketing/sections/header.templ b/pkg/nebula/marketing/nav_header.templ similarity index 98% rename from pkg/nebula/components/marketing/sections/header.templ rename to pkg/nebula/marketing/nav_header.templ index e5ff3b986..c18642e8a 100644 --- a/pkg/nebula/components/marketing/sections/header.templ +++ b/pkg/nebula/marketing/nav_header.templ @@ -1,4 +1,4 @@ -package sections +package marketing templ Header() { diff --git a/pkg/nebula/components/marketing/sections/header_templ.go b/pkg/nebula/marketing/nav_header_templ.go similarity index 99% rename from pkg/nebula/components/marketing/sections/header_templ.go rename to pkg/nebula/marketing/nav_header_templ.go index b40a38a4e..1f5e9be04 100644 --- a/pkg/nebula/components/marketing/sections/header_templ.go +++ b/pkg/nebula/marketing/nav_header_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. diff --git a/pkg/nebula/marketing/page.templ b/pkg/nebula/marketing/page.templ new file mode 100644 index 000000000..5a13b678e --- /dev/null +++ b/pkg/nebula/marketing/page.templ @@ -0,0 +1,21 @@ +package marketing + +import "github.com/onsonr/sonr/pkg/nebula/global/styles" + +// ╭─────────────────────────────────────────────────────────╮ +// │ Final Rendering │ +// ╰─────────────────────────────────────────────────────────╯ + +// View renders the home page +templ View() { + @styles.LayoutNoBody("Sonr.ID", true) { + @Header() + @Hero() + @Highlights() + @Mission() + @Architecture() + @Lowlights() + @CallToAction() + @Footer() + } +} diff --git a/pkg/nebula/components/marketing/page_templ.go b/pkg/nebula/marketing/page_templ.go similarity index 67% rename from pkg/nebula/components/marketing/page_templ.go rename to pkg/nebula/marketing/page_templ.go index 45cd4cc4d..dc08a6768 100644 --- a/pkg/nebula/components/marketing/page_templ.go +++ b/pkg/nebula/marketing/page_templ.go @@ -8,30 +8,7 @@ package marketing import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" -import ( - "github.com/labstack/echo/v4" - "github.com/onsonr/sonr/internal/ctx" - "github.com/onsonr/sonr/pkg/nebula/components/marketing/sections" - "github.com/onsonr/sonr/pkg/nebula/global/styles" - "log" -) - -// ╭───────────────────────────────────────────────────────────╮ -// │ Home Routes - Marketing │ -// ╰───────────────────────────────────────────────────────────╯ - -func HomeRoute(c echo.Context) error { - s, err := ctx.GetHWAYContext(c) - if err != nil { - return err - } - log.Printf("Session ID: %s", s.ID()) - return ctx.RenderTempl(c, View()) -} - -// ╭───────────────────────────────────────────────────────────╮ -// │ Static Content Values │ -// ╰───────────────────────────────────────────────────────────╯ +import "github.com/onsonr/sonr/pkg/nebula/global/styles" // ╭─────────────────────────────────────────────────────────╮ // │ Final Rendering │ @@ -71,7 +48,7 @@ func View() templ.Component { }() } ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Err = sections.Header().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Header().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -79,7 +56,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.Hero().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Hero().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -87,7 +64,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.Highlights().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Highlights().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -95,7 +72,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.Mission().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Mission().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -103,7 +80,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.Architecture().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Architecture().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -111,7 +88,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.Lowlights().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Lowlights().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -119,7 +96,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.CallToAction().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = CallToAction().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -127,7 +104,7 @@ func View() templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = sections.Footer().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = Footer().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } diff --git a/pkg/nebula/components/marketing/sections/architecture.templ b/pkg/nebula/marketing/section_arch.templ similarity index 96% rename from pkg/nebula/components/marketing/sections/architecture.templ rename to pkg/nebula/marketing/section_arch.templ index 2a53c8176..8c828a50e 100644 --- a/pkg/nebula/components/marketing/sections/architecture.templ +++ b/pkg/nebula/marketing/section_arch.templ @@ -1,6 +1,9 @@ -package sections +package marketing -import models "github.com/onsonr/sonr/internal/orm/marketing" +import ( + models "github.com/onsonr/sonr/internal/orm/marketing" + "github.com/onsonr/sonr/pkg/nebula/global" +) // ╭───────────────────────────────────────────────────────────╮ // │ Data Model │ @@ -14,7 +17,7 @@ var arch = &models.Architecture{ Title: "Decentralized Identity", Desc: "Sonr leverages the latest specifications from W3C, DIF, and ICF to essentially have an Interchain-Connected, Smart Account System - seamlessly authenticated with PassKeys.", Image: &models.Image{ - Src: HardwareWallet.Src(), + Src: global.HardwareWallet.Src(), Width: "721", Height: "280", }, @@ -23,7 +26,7 @@ var arch = &models.Architecture{ Title: "IPFS Vaults", Desc: "Completely distributed, encrypted, and decentralized storage for your data.", Image: &models.Image{ - Src: DecentralizedNetwork.Src(), + Src: global.DecentralizedNetwork.Src(), Width: "342", Height: "280", }, @@ -32,7 +35,7 @@ var arch = &models.Architecture{ Title: "Service Records", Desc: "On-chain validated services created by Developers for secure transmission of user data.", Image: &models.Image{ - Src: DefiDashboard.Src(), + Src: global.DefiDashboard.Src(), Width: "342", Height: "280", }, @@ -41,7 +44,7 @@ var arch = &models.Architecture{ Title: "Authentication & Authorization", Desc: "Sonr leverages decentralized Macaroons and Multi-Party Computation to provide a secure and decentralized authentication and authorization system.", Image: &models.Image{ - Src: PrivateKey.Src(), + Src: global.PrivateKey.Src(), Width: "342", Height: "280", }, @@ -50,7 +53,7 @@ var arch = &models.Architecture{ Title: "First-Class Exchange", Desc: "Sonr integrates with the IBC protocol allowing for seamless integration with popular exchanges such as OKX, Binance, and Osmosis.", Image: &models.Image{ - Src: CrossChainBridge.Src(), + Src: global.CrossChainBridge.Src(), Width: "342", Height: "280", }, diff --git a/pkg/nebula/components/marketing/sections/architecture_templ.go b/pkg/nebula/marketing/section_arch_templ.go similarity index 87% rename from pkg/nebula/components/marketing/sections/architecture_templ.go rename to pkg/nebula/marketing/section_arch_templ.go index b2908b1ee..d81293a73 100644 --- a/pkg/nebula/components/marketing/sections/architecture_templ.go +++ b/pkg/nebula/marketing/section_arch_templ.go @@ -1,14 +1,17 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" -import models "github.com/onsonr/sonr/internal/orm/marketing" +import ( + models "github.com/onsonr/sonr/internal/orm/marketing" + "github.com/onsonr/sonr/pkg/nebula/global" +) // ╭───────────────────────────────────────────────────────────╮ // │ Data Model │ @@ -22,7 +25,7 @@ var arch = &models.Architecture{ Title: "Decentralized Identity", Desc: "Sonr leverages the latest specifications from W3C, DIF, and ICF to essentially have an Interchain-Connected, Smart Account System - seamlessly authenticated with PassKeys.", Image: &models.Image{ - Src: HardwareWallet.Src(), + Src: global.HardwareWallet.Src(), Width: "721", Height: "280", }, @@ -31,7 +34,7 @@ var arch = &models.Architecture{ Title: "IPFS Vaults", Desc: "Completely distributed, encrypted, and decentralized storage for your data.", Image: &models.Image{ - Src: DecentralizedNetwork.Src(), + Src: global.DecentralizedNetwork.Src(), Width: "342", Height: "280", }, @@ -40,7 +43,7 @@ var arch = &models.Architecture{ Title: "Service Records", Desc: "On-chain validated services created by Developers for secure transmission of user data.", Image: &models.Image{ - Src: DefiDashboard.Src(), + Src: global.DefiDashboard.Src(), Width: "342", Height: "280", }, @@ -49,7 +52,7 @@ var arch = &models.Architecture{ Title: "Authentication & Authorization", Desc: "Sonr leverages decentralized Macaroons and Multi-Party Computation to provide a secure and decentralized authentication and authorization system.", Image: &models.Image{ - Src: PrivateKey.Src(), + Src: global.PrivateKey.Src(), Width: "342", Height: "280", }, @@ -58,7 +61,7 @@ var arch = &models.Architecture{ Title: "First-Class Exchange", Desc: "Sonr integrates with the IBC protocol allowing for seamless integration with popular exchanges such as OKX, Binance, and Osmosis.", Image: &models.Image{ - Src: CrossChainBridge.Src(), + Src: global.CrossChainBridge.Src(), Width: "342", Height: "280", }, @@ -98,7 +101,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var2 string templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Heading) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 76, Col: 20} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 79, Col: 20} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2)) if templ_7745c5c3_Err != nil { @@ -111,7 +114,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var3 string templ_7745c5c3_Var3, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Subtitle) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 79, Col: 21} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 82, Col: 21} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var3)) if templ_7745c5c3_Err != nil { @@ -124,7 +127,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var4 string templ_7745c5c3_Var4, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Primary.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 101, Col: 29} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 104, Col: 29} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var4)) if templ_7745c5c3_Err != nil { @@ -137,7 +140,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var5 string templ_7745c5c3_Var5, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Primary.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 105, Col: 27} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 108, Col: 27} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var5)) if templ_7745c5c3_Err != nil { @@ -150,7 +153,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var6 string templ_7745c5c3_Var6, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Primary.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 111, Col: 36} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 114, Col: 36} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var6)) if templ_7745c5c3_Err != nil { @@ -163,7 +166,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var7 string templ_7745c5c3_Var7, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Secondary.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 134, Col: 31} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 137, Col: 31} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var7)) if templ_7745c5c3_Err != nil { @@ -176,7 +179,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var8 string templ_7745c5c3_Var8, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Secondary.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 138, Col: 29} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 141, Col: 29} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var8)) if templ_7745c5c3_Err != nil { @@ -189,7 +192,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var9 string templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Secondary.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 144, Col: 38} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 147, Col: 38} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9)) if templ_7745c5c3_Err != nil { @@ -202,7 +205,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var10 string templ_7745c5c3_Var10, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Tertiary.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 167, Col: 30} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 170, Col: 30} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var10)) if templ_7745c5c3_Err != nil { @@ -215,7 +218,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var11 string templ_7745c5c3_Var11, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Tertiary.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 171, Col: 28} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 174, Col: 28} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var11)) if templ_7745c5c3_Err != nil { @@ -228,7 +231,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var12 string templ_7745c5c3_Var12, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Tertiary.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 177, Col: 37} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 180, Col: 37} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var12)) if templ_7745c5c3_Err != nil { @@ -241,7 +244,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var13 string templ_7745c5c3_Var13, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Quaternary.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 200, Col: 32} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 203, Col: 32} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var13)) if templ_7745c5c3_Err != nil { @@ -254,7 +257,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var14 string templ_7745c5c3_Var14, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Quaternary.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 204, Col: 30} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 207, Col: 30} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var14)) if templ_7745c5c3_Err != nil { @@ -267,7 +270,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var15 string templ_7745c5c3_Var15, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Quaternary.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 210, Col: 39} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 213, Col: 39} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var15)) if templ_7745c5c3_Err != nil { @@ -280,7 +283,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var16 string templ_7745c5c3_Var16, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Quinary.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 233, Col: 29} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 236, Col: 29} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var16)) if templ_7745c5c3_Err != nil { @@ -293,7 +296,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var17 string templ_7745c5c3_Var17, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Quinary.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 237, Col: 27} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 240, Col: 27} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var17)) if templ_7745c5c3_Err != nil { @@ -306,7 +309,7 @@ func Architecture() templ.Component { var templ_7745c5c3_Var18 string templ_7745c5c3_Var18, templ_7745c5c3_Err = templ.JoinStringErrs(arch.Quinary.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/architecture.templ`, Line: 243, Col: 36} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_arch.templ`, Line: 246, Col: 36} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var18)) if templ_7745c5c3_Err != nil { diff --git a/pkg/nebula/marketing/section_cta.templ b/pkg/nebula/marketing/section_cta.templ new file mode 100644 index 000000000..f32e9f6b0 --- /dev/null +++ b/pkg/nebula/marketing/section_cta.templ @@ -0,0 +1,91 @@ +package marketing + +import models "github.com/onsonr/sonr/internal/orm/marketing" + +// ╭───────────────────────────────────────────────────────────╮ +// │ Data Model │ +// ╰───────────────────────────────────────────────────────────╯ + +var cta = &models.CallToAction{ + Logo: &models.Image{ + Src: "https://cdn.sonr.id/logo-zinc.svg", + Width: "60", + Height: "60", + }, + Heading: "Take control of your Identity", + Subtitle: "Sonr is a decentralized, permissionless, and censorship-resistant identity network.", + Primary: &models.Button{ + Href: "request-demo.html", + Text: "Register", + }, + Secondary: &models.Button{ + Href: "#0", + Text: "Learn More", + }, +} + +// ╭───────────────────────────────────────────────────────────╮ +// │ Render Section View │ +// ╰───────────────────────────────────────────────────────────╯ +templ CallToAction() { +
+
+
+
+
+ + Logo + +
+

+ Take control of your Identity + + today + + +

+

Sonr removes creative distances by connecting beginners, pros, and every team in between. Are you ready to start your journey?

+
+
+ Register +
+
+ Log in +
+
+
+ +
+
    +
  • + + +
  • +
  • + +
  • +
  • + +
  • +
  • + + + + + + +
  • +
  • + +
  • +
  • + +
  • +
+
+
+
+
+} diff --git a/pkg/nebula/marketing/section_cta_templ.go b/pkg/nebula/marketing/section_cta_templ.go new file mode 100644 index 000000000..f9457fa50 --- /dev/null +++ b/pkg/nebula/marketing/section_cta_templ.go @@ -0,0 +1,67 @@ +// Code generated by templ - DO NOT EDIT. + +// templ: version: v0.2.778 +package marketing + +//lint:file-ignore SA4006 This context is only used if a nested component is present. + +import "github.com/a-h/templ" +import templruntime "github.com/a-h/templ/runtime" + +import models "github.com/onsonr/sonr/internal/orm/marketing" + +// ╭───────────────────────────────────────────────────────────╮ +// │ Data Model │ +// ╰───────────────────────────────────────────────────────────╯ + +var cta = &models.CallToAction{ + Logo: &models.Image{ + Src: "https://cdn.sonr.id/logo-zinc.svg", + Width: "60", + Height: "60", + }, + Heading: "Take control of your Identity", + Subtitle: "Sonr is a decentralized, permissionless, and censorship-resistant identity network.", + Primary: &models.Button{ + Href: "request-demo.html", + Text: "Register", + }, + Secondary: &models.Button{ + Href: "#0", + Text: "Learn More", + }, +} + +// ╭───────────────────────────────────────────────────────────╮ +// │ Render Section View │ +// ╰───────────────────────────────────────────────────────────╯ +func CallToAction() templ.Component { + return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { + templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context + if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { + return templ_7745c5c3_CtxErr + } + templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W) + if !templ_7745c5c3_IsBuffer { + defer func() { + templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer) + if templ_7745c5c3_Err == nil { + templ_7745c5c3_Err = templ_7745c5c3_BufErr + } + }() + } + ctx = templ.InitializeContext(ctx) + templ_7745c5c3_Var1 := templ.GetChildren(ctx) + if templ_7745c5c3_Var1 == nil { + templ_7745c5c3_Var1 = templ.NopComponent + } + ctx = templ.ClearChildren(ctx) + _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("
\"Logo\"

Take control of your Identity today

Sonr removes creative distances by connecting beginners, pros, and every team in between. Are you ready to start your journey?

") + if templ_7745c5c3_Err != nil { + return templ_7745c5c3_Err + } + return templ_7745c5c3_Err + }) +} + +var _ = templruntime.GeneratedTemplate diff --git a/pkg/nebula/components/marketing/sections/hero.templ b/pkg/nebula/marketing/section_hero.templ similarity index 99% rename from pkg/nebula/components/marketing/sections/hero.templ rename to pkg/nebula/marketing/section_hero.templ index b33648706..749d66b19 100644 --- a/pkg/nebula/components/marketing/sections/hero.templ +++ b/pkg/nebula/marketing/section_hero.templ @@ -1,4 +1,4 @@ -package sections +package marketing import ( "fmt" diff --git a/pkg/nebula/components/marketing/sections/hero_templ.go b/pkg/nebula/marketing/section_hero_templ.go similarity index 93% rename from pkg/nebula/components/marketing/sections/hero_templ.go rename to pkg/nebula/marketing/section_hero_templ.go index ba8cd31d2..5ca335062 100644 --- a/pkg/nebula/components/marketing/sections/hero_templ.go +++ b/pkg/nebula/marketing/section_hero_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -80,7 +80,7 @@ func Hero() templ.Component { var templ_7745c5c3_Var2 string templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(hero.Subtitle) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 49, Col: 22} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 49, Col: 22} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2)) if templ_7745c5c3_Err != nil { @@ -146,7 +146,7 @@ func heroTitle(first string, emphasis string, second string) templ.Component { var templ_7745c5c3_Var4 string templ_7745c5c3_Var4, templ_7745c5c3_Err = templ.JoinStringErrs(first) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 66, Col: 9} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 66, Col: 9} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var4)) if templ_7745c5c3_Err != nil { @@ -159,7 +159,7 @@ func heroTitle(first string, emphasis string, second string) templ.Component { var templ_7745c5c3_Var5 string templ_7745c5c3_Var5, templ_7745c5c3_Err = templ.JoinStringErrs(emphasis) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 68, Col: 13} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 68, Col: 13} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var5)) if templ_7745c5c3_Err != nil { @@ -172,7 +172,7 @@ func heroTitle(first string, emphasis string, second string) templ.Component { var templ_7745c5c3_Var6 string templ_7745c5c3_Var6, templ_7745c5c3_Err = templ.JoinStringErrs(second) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 73, Col: 10} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 73, Col: 10} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var6)) if templ_7745c5c3_Err != nil { @@ -214,7 +214,7 @@ func heroImage(hero *models.Hero) templ.Component { var templ_7745c5c3_Var8 string templ_7745c5c3_Var8, templ_7745c5c3_Err = templ.JoinStringErrs(hero.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 82, Col: 23} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 82, Col: 23} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var8)) if templ_7745c5c3_Err != nil { @@ -227,7 +227,7 @@ func heroImage(hero *models.Hero) templ.Component { var templ_7745c5c3_Var9 string templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(hero.Image.Width) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 83, Col: 27} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 83, Col: 27} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9)) if templ_7745c5c3_Err != nil { @@ -240,7 +240,7 @@ func heroImage(hero *models.Hero) templ.Component { var templ_7745c5c3_Var10 string templ_7745c5c3_Var10, templ_7745c5c3_Err = templ.JoinStringErrs(hero.Image.Height) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 84, Col: 29} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 84, Col: 29} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var10)) if templ_7745c5c3_Err != nil { @@ -287,7 +287,7 @@ func stats(stats []*models.Stat) templ.Component { var templ_7745c5c3_Var12 string templ_7745c5c3_Var12, templ_7745c5c3_Err = templ.JoinStringErrs(counterXData(item.Value)) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 96, Col: 122} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 96, Col: 122} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var12)) if templ_7745c5c3_Err != nil { @@ -300,7 +300,7 @@ func stats(stats []*models.Stat) templ.Component { var templ_7745c5c3_Var13 string templ_7745c5c3_Var13, templ_7745c5c3_Err = templ.JoinStringErrs(item.Value) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 96, Col: 159} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 96, Col: 159} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var13)) if templ_7745c5c3_Err != nil { @@ -313,7 +313,7 @@ func stats(stats []*models.Stat) templ.Component { var templ_7745c5c3_Var14 string templ_7745c5c3_Var14, templ_7745c5c3_Err = templ.JoinStringErrs(item.Denom) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 96, Col: 180} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 96, Col: 180} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var14)) if templ_7745c5c3_Err != nil { @@ -326,7 +326,7 @@ func stats(stats []*models.Stat) templ.Component { var templ_7745c5c3_Var15 string templ_7745c5c3_Var15, templ_7745c5c3_Err = templ.JoinStringErrs(item.Label) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/hero.templ`, Line: 97, Col: 50} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_hero.templ`, Line: 97, Col: 50} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var15)) if templ_7745c5c3_Err != nil { diff --git a/pkg/nebula/components/marketing/sections/highlights.templ b/pkg/nebula/marketing/section_highlights.templ similarity index 99% rename from pkg/nebula/components/marketing/sections/highlights.templ rename to pkg/nebula/marketing/section_highlights.templ index 4dae427f7..711a452b8 100644 --- a/pkg/nebula/components/marketing/sections/highlights.templ +++ b/pkg/nebula/marketing/section_highlights.templ @@ -1,4 +1,4 @@ -package sections +package marketing import ( "fmt" diff --git a/pkg/nebula/components/marketing/sections/highlights_templ.go b/pkg/nebula/marketing/section_highlights_templ.go similarity index 90% rename from pkg/nebula/components/marketing/sections/highlights_templ.go rename to pkg/nebula/marketing/section_highlights_templ.go index 76090a1c8..08f0b6d0b 100644 --- a/pkg/nebula/components/marketing/sections/highlights_templ.go +++ b/pkg/nebula/marketing/section_highlights_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -76,7 +76,7 @@ func Highlights() templ.Component { var templ_7745c5c3_Var2 string templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(highlights.Heading) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 52, Col: 26} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 52, Col: 26} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2)) if templ_7745c5c3_Err != nil { @@ -89,7 +89,7 @@ func Highlights() templ.Component { var templ_7745c5c3_Var3 string templ_7745c5c3_Var3, templ_7745c5c3_Err = templ.JoinStringErrs(highlights.Subtitle) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 55, Col: 27} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 55, Col: 27} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var3)) if templ_7745c5c3_Err != nil { @@ -151,7 +151,7 @@ func highlightTab(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var5 string templ_7745c5c3_Var5, templ_7745c5c3_Err = templ.JoinStringErrs(getSelectedClass(index)) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 74, Col: 34} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 74, Col: 34} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var5)) if templ_7745c5c3_Err != nil { @@ -164,7 +164,7 @@ func highlightTab(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var6 string templ_7745c5c3_Var6, templ_7745c5c3_Err = templ.JoinStringErrs(getClickPrevent(index)) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 76, Col: 41} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 76, Col: 41} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var6)) if templ_7745c5c3_Err != nil { @@ -177,7 +177,7 @@ func highlightTab(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var7 string templ_7745c5c3_Var7, templ_7745c5c3_Err = templ.JoinStringErrs(highlight.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 80, Col: 21} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 80, Col: 21} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var7)) if templ_7745c5c3_Err != nil { @@ -190,7 +190,7 @@ func highlightTab(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var8 string templ_7745c5c3_Var8, templ_7745c5c3_Err = templ.JoinStringErrs(getShowBorder(index)) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 83, Col: 33} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 83, Col: 33} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var8)) if templ_7745c5c3_Err != nil { @@ -203,7 +203,7 @@ func highlightTab(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var9 string templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(highlight.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 95, Col: 19} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 95, Col: 19} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9)) if templ_7745c5c3_Err != nil { @@ -245,7 +245,7 @@ func highlightCard(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var11 string templ_7745c5c3_Var11, templ_7745c5c3_Err = templ.JoinStringErrs(getXShow(index)) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 103, Col: 26} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 103, Col: 26} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var11)) if templ_7745c5c3_Err != nil { @@ -258,7 +258,7 @@ func highlightCard(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var12 string templ_7745c5c3_Var12, templ_7745c5c3_Err = templ.JoinStringErrs(highlight.Image.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 114, Col: 29} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 114, Col: 29} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var12)) if templ_7745c5c3_Err != nil { @@ -271,7 +271,7 @@ func highlightCard(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var13 string templ_7745c5c3_Var13, templ_7745c5c3_Err = templ.JoinStringErrs(highlight.Image.Width) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 115, Col: 33} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 115, Col: 33} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var13)) if templ_7745c5c3_Err != nil { @@ -284,7 +284,7 @@ func highlightCard(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var14 string templ_7745c5c3_Var14, templ_7745c5c3_Err = templ.JoinStringErrs(highlight.Image.Height) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 116, Col: 35} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 116, Col: 35} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var14)) if templ_7745c5c3_Err != nil { @@ -297,7 +297,7 @@ func highlightCard(index int, highlight *models.Feature) templ.Component { var templ_7745c5c3_Var15 string templ_7745c5c3_Var15, templ_7745c5c3_Err = templ.JoinStringErrs(highlight.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/highlights.templ`, Line: 117, Col: 25} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_highlights.templ`, Line: 117, Col: 25} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var15)) if templ_7745c5c3_Err != nil { diff --git a/pkg/nebula/components/marketing/sections/lowlights.templ b/pkg/nebula/marketing/section_lowlights.templ similarity index 90% rename from pkg/nebula/components/marketing/sections/lowlights.templ rename to pkg/nebula/marketing/section_lowlights.templ index 3c819dfa0..40c3ebc66 100644 --- a/pkg/nebula/components/marketing/sections/lowlights.templ +++ b/pkg/nebula/marketing/section_lowlights.templ @@ -1,7 +1,8 @@ -package sections +package marketing import ( models "github.com/onsonr/sonr/internal/orm/marketing" + global "github.com/onsonr/sonr/pkg/nebula/global" ) // ╭───────────────────────────────────────────────────────────╮ @@ -15,7 +16,7 @@ var lowlights = &models.Lowlights{ FullName: "0xDesigner", Username: "@0xDesigner", Avatar: &models.Image{ - Src: Avatar0xDesigner.Src(), + Src: global.Avatar0xDesigner.Src(), Width: "44", Height: "44", }, @@ -25,7 +26,7 @@ var lowlights = &models.Lowlights{ FullName: "Alex Recouso", Username: "@alexrecouso", Avatar: &models.Image{ - Src: AvatarAlexRecouso.Src(), + Src: global.AvatarAlexRecouso.Src(), Width: "44", Height: "44", }, @@ -35,7 +36,7 @@ var lowlights = &models.Lowlights{ FullName: "Chjango Unchained", Username: "@chjango", Avatar: &models.Image{ - Src: AvatarChjango.Src(), + Src: global.AvatarChjango.Src(), Width: "44", Height: "44", }, @@ -45,19 +46,19 @@ var lowlights = &models.Lowlights{ FullName: "Gwart", Username: "@GwartyGwart", Avatar: &models.Image{ - Src: AvatarGwart.Src(), + Src: global.AvatarGwart.Src(), Width: "44", Height: "44", }, Quote: " Base is incredible. Most centralized l2. Least details about their plans to decentralize. Keeps OP cabal quiet by pretending to care about quadratic voting and giving 10% tithe. Pays Ethereum mainnet virtually nothing. Runs yuppie granola ad campaigns.", }, - }, + }, LowerQuotes: []*models.Testimonial{ { FullName: "winnie", Username: "@winnielaux_", Avatar: &models.Image{ - Src: AvatarWinnieLaux.Src(), + Src: global.AvatarWinnieLaux.Src(), Width: "44", Height: "44", }, @@ -67,7 +68,7 @@ var lowlights = &models.Lowlights{ FullName: "Jelena", Username: "@jelena_noble", Avatar: &models.Image{ - Src: AvatarJelenaNoble.Src(), + Src: global.AvatarJelenaNoble.Src(), Width: "44", Height: "44", }, @@ -77,7 +78,7 @@ var lowlights = &models.Lowlights{ FullName: "accountless", Username: "@alexanderchopan", Avatar: &models.Image{ - Src: AvatarAccountless.Src(), + Src: global.AvatarAccountless.Src(), Width: "44", Height: "44", }, @@ -87,7 +88,7 @@ var lowlights = &models.Lowlights{ FullName: "Unusual Whales", Username: "@unusual_whales", Avatar: &models.Image{ - Src: AvatarUnusualWhales.Src(), + Src: global.AvatarUnusualWhales.Src(), Width: "44", Height: "44", }, @@ -125,7 +126,7 @@ templ Lowlights() {
for _,quote := range lowlights.UpperQuotes { @quoteItem(quote) - } + }
@@ -141,7 +142,7 @@ templ Lowlights() {
for _,quote := range lowlights.LowerQuotes { @quoteItem(quote) - } + }
@@ -150,7 +151,7 @@ templ Lowlights() { } templ quoteItem(quote *models.Testimonial) { -
+
Testimonial 01
diff --git a/pkg/nebula/components/marketing/sections/lowlights_templ.go b/pkg/nebula/marketing/section_lowlights_templ.go similarity index 90% rename from pkg/nebula/components/marketing/sections/lowlights_templ.go rename to pkg/nebula/marketing/section_lowlights_templ.go index 73a3d0025..a0c495788 100644 --- a/pkg/nebula/components/marketing/sections/lowlights_templ.go +++ b/pkg/nebula/marketing/section_lowlights_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -10,6 +10,7 @@ import templruntime "github.com/a-h/templ/runtime" import ( models "github.com/onsonr/sonr/internal/orm/marketing" + global "github.com/onsonr/sonr/pkg/nebula/global" ) // ╭───────────────────────────────────────────────────────────╮ @@ -23,7 +24,7 @@ var lowlights = &models.Lowlights{ FullName: "0xDesigner", Username: "@0xDesigner", Avatar: &models.Image{ - Src: Avatar0xDesigner.Src(), + Src: global.Avatar0xDesigner.Src(), Width: "44", Height: "44", }, @@ -33,7 +34,7 @@ var lowlights = &models.Lowlights{ FullName: "Alex Recouso", Username: "@alexrecouso", Avatar: &models.Image{ - Src: AvatarAlexRecouso.Src(), + Src: global.AvatarAlexRecouso.Src(), Width: "44", Height: "44", }, @@ -43,7 +44,7 @@ var lowlights = &models.Lowlights{ FullName: "Chjango Unchained", Username: "@chjango", Avatar: &models.Image{ - Src: AvatarChjango.Src(), + Src: global.AvatarChjango.Src(), Width: "44", Height: "44", }, @@ -53,7 +54,7 @@ var lowlights = &models.Lowlights{ FullName: "Gwart", Username: "@GwartyGwart", Avatar: &models.Image{ - Src: AvatarGwart.Src(), + Src: global.AvatarGwart.Src(), Width: "44", Height: "44", }, @@ -65,7 +66,7 @@ var lowlights = &models.Lowlights{ FullName: "winnie", Username: "@winnielaux_", Avatar: &models.Image{ - Src: AvatarWinnieLaux.Src(), + Src: global.AvatarWinnieLaux.Src(), Width: "44", Height: "44", }, @@ -75,7 +76,7 @@ var lowlights = &models.Lowlights{ FullName: "Jelena", Username: "@jelena_noble", Avatar: &models.Image{ - Src: AvatarJelenaNoble.Src(), + Src: global.AvatarJelenaNoble.Src(), Width: "44", Height: "44", }, @@ -85,7 +86,7 @@ var lowlights = &models.Lowlights{ FullName: "accountless", Username: "@alexanderchopan", Avatar: &models.Image{ - Src: AvatarAccountless.Src(), + Src: global.AvatarAccountless.Src(), Width: "44", Height: "44", }, @@ -95,7 +96,7 @@ var lowlights = &models.Lowlights{ FullName: "Unusual Whales", Username: "@unusual_whales", Avatar: &models.Image{ - Src: AvatarUnusualWhales.Src(), + Src: global.AvatarUnusualWhales.Src(), Width: "44", Height: "44", }, @@ -137,7 +138,7 @@ func Lowlights() templ.Component { var templ_7745c5c3_Var2 string templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(lowlights.Heading) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 110, Col: 25} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 111, Col: 25} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2)) if templ_7745c5c3_Err != nil { @@ -199,7 +200,7 @@ func quoteItem(quote *models.Testimonial) templ.Component { var templ_7745c5c3_Var4 string templ_7745c5c3_Var4, templ_7745c5c3_Err = templ.JoinStringErrs(quote.Avatar.Src) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 155, Col: 65} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 156, Col: 65} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var4)) if templ_7745c5c3_Err != nil { @@ -212,7 +213,7 @@ func quoteItem(quote *models.Testimonial) templ.Component { var templ_7745c5c3_Var5 string templ_7745c5c3_Var5, templ_7745c5c3_Err = templ.JoinStringErrs(quote.Avatar.Width) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 155, Col: 94} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 156, Col: 94} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var5)) if templ_7745c5c3_Err != nil { @@ -225,7 +226,7 @@ func quoteItem(quote *models.Testimonial) templ.Component { var templ_7745c5c3_Var6 string templ_7745c5c3_Var6, templ_7745c5c3_Err = templ.JoinStringErrs(quote.Avatar.Height) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 155, Col: 125} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 156, Col: 125} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var6)) if templ_7745c5c3_Err != nil { @@ -238,7 +239,7 @@ func quoteItem(quote *models.Testimonial) templ.Component { var templ_7745c5c3_Var7 string templ_7745c5c3_Var7, templ_7745c5c3_Err = templ.JoinStringErrs(quote.FullName) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 157, Col: 74} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 158, Col: 74} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var7)) if templ_7745c5c3_Err != nil { @@ -251,7 +252,7 @@ func quoteItem(quote *models.Testimonial) templ.Component { var templ_7745c5c3_Var8 string templ_7745c5c3_Var8, templ_7745c5c3_Err = templ.JoinStringErrs(quote.Username) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 159, Col: 107} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 160, Col: 107} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var8)) if templ_7745c5c3_Err != nil { @@ -264,7 +265,7 @@ func quoteItem(quote *models.Testimonial) templ.Component { var templ_7745c5c3_Var9 string templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(quote.Quote) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/lowlights.templ`, Line: 164, Col: 16} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_lowlights.templ`, Line: 165, Col: 16} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9)) if templ_7745c5c3_Err != nil { diff --git a/pkg/nebula/components/marketing/sections/mission.templ b/pkg/nebula/marketing/section_mission.templ similarity index 99% rename from pkg/nebula/components/marketing/sections/mission.templ rename to pkg/nebula/marketing/section_mission.templ index fb8ba01cb..738ffcd50 100644 --- a/pkg/nebula/components/marketing/sections/mission.templ +++ b/pkg/nebula/marketing/section_mission.templ @@ -1,4 +1,4 @@ -package sections +package marketing import models "github.com/onsonr/sonr/internal/orm/marketing" diff --git a/pkg/nebula/components/marketing/sections/mission_templ.go b/pkg/nebula/marketing/section_mission_templ.go similarity index 94% rename from pkg/nebula/components/marketing/sections/mission_templ.go rename to pkg/nebula/marketing/section_mission_templ.go index 17213b956..e46abce2a 100644 --- a/pkg/nebula/components/marketing/sections/mission_templ.go +++ b/pkg/nebula/marketing/section_mission_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package sections +package marketing //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -60,7 +60,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var2 string templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Eyebrow) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 45, Col: 25} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 45, Col: 25} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2)) if templ_7745c5c3_Err != nil { @@ -73,7 +73,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var3 string templ_7745c5c3_Var3, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Heading) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 50, Col: 25} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 50, Col: 25} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var3)) if templ_7745c5c3_Err != nil { @@ -86,7 +86,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var4 string templ_7745c5c3_Var4, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Subtitle) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 53, Col: 26} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 53, Col: 26} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var4)) if templ_7745c5c3_Err != nil { @@ -99,7 +99,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var5 string templ_7745c5c3_Var5, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Experience.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 77, Col: 36} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 77, Col: 36} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var5)) if templ_7745c5c3_Err != nil { @@ -112,7 +112,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var6 string templ_7745c5c3_Var6, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Experience.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 80, Col: 35} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 80, Col: 35} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var6)) if templ_7745c5c3_Err != nil { @@ -125,7 +125,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var7 string templ_7745c5c3_Var7, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Compliance.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 103, Col: 36} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 103, Col: 36} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var7)) if templ_7745c5c3_Err != nil { @@ -138,7 +138,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var8 string templ_7745c5c3_Var8, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Compliance.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 106, Col: 35} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 106, Col: 35} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var8)) if templ_7745c5c3_Err != nil { @@ -151,7 +151,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var9 string templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Interoperability.Title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 129, Col: 42} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 129, Col: 42} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9)) if templ_7745c5c3_Err != nil { @@ -164,7 +164,7 @@ func Mission() templ.Component { var templ_7745c5c3_Var10 string templ_7745c5c3_Var10, templ_7745c5c3_Err = templ.JoinStringErrs(mission.Interoperability.Desc) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `components/marketing/sections/mission.templ`, Line: 132, Col: 41} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `marketing/section_mission.templ`, Line: 132, Col: 41} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var10)) if templ_7745c5c3_Err != nil { diff --git a/pkg/nebula/components/authentication/modal.templ b/pkg/nebula/modals/authentication.templ similarity index 79% rename from pkg/nebula/components/authentication/modal.templ rename to pkg/nebula/modals/authentication.templ index 0d38ae341..8e49f70a5 100644 --- a/pkg/nebula/components/authentication/modal.templ +++ b/pkg/nebula/modals/authentication.templ @@ -1,29 +1,28 @@ -package authentication +package modals import ( "github.com/labstack/echo/v4" - "github.com/onsonr/sonr/pkg/nebula/components/authentication/sections" + "github.com/onsonr/sonr/pkg/nebula/auth" "github.com/onsonr/sonr/pkg/nebula/global/styles" ) // RegisterModal returns the Register Modal. templ RegisterModal(c echo.Context) { @styles.OpenModal("Account Registration", "Enter your account information below to create your account.") { - @sections.RegisterStart() + @auth.RegisterStart() } } // LoginModal returns the Login Modal. templ LoginModal(c echo.Context) { @styles.OpenModal("Account Registration", "Enter your account information below to create your account.") { - @sections.LoginStart() + @auth.LoginStart() } } // AuthorizeModal returns the Authorize Modal. templ AuthorizeModal(c echo.Context) { @styles.OpenModal("Account Registration", "Enter your account information below to create your account.") { - @sections.AuthorizeStart() + @auth.AuthorizeStart() } } - diff --git a/pkg/nebula/components/authentication/modal_templ.go b/pkg/nebula/modals/authentication_templ.go similarity index 95% rename from pkg/nebula/components/authentication/modal_templ.go rename to pkg/nebula/modals/authentication_templ.go index cc1f9b037..4c2e9d1c7 100644 --- a/pkg/nebula/components/authentication/modal_templ.go +++ b/pkg/nebula/modals/authentication_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package authentication +package modals //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -10,7 +10,7 @@ import templruntime "github.com/a-h/templ/runtime" import ( "github.com/labstack/echo/v4" - "github.com/onsonr/sonr/pkg/nebula/components/authentication/sections" + "github.com/onsonr/sonr/pkg/nebula/auth" "github.com/onsonr/sonr/pkg/nebula/global/styles" ) @@ -48,7 +48,7 @@ func RegisterModal(c echo.Context) templ.Component { }() } ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Err = sections.RegisterStart().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = auth.RegisterStart().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -96,7 +96,7 @@ func LoginModal(c echo.Context) templ.Component { }() } ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Err = sections.LoginStart().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = auth.LoginStart().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -144,7 +144,7 @@ func AuthorizeModal(c echo.Context) templ.Component { }() } ctx = templ.InitializeContext(ctx) - templ_7745c5c3_Err = sections.AuthorizeStart().Render(ctx, templ_7745c5c3_Buffer) + templ_7745c5c3_Err = auth.AuthorizeStart().Render(ctx, templ_7745c5c3_Buffer) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } diff --git a/pkg/nebula/components/marketing/modals/intro_video.templ b/pkg/nebula/modals/intro_video.templ similarity index 100% rename from pkg/nebula/components/marketing/modals/intro_video.templ rename to pkg/nebula/modals/intro_video.templ diff --git a/pkg/nebula/components/marketing/modals/intro_video_templ.go b/pkg/nebula/modals/intro_video_templ.go similarity index 100% rename from pkg/nebula/components/marketing/modals/intro_video_templ.go rename to pkg/nebula/modals/intro_video_templ.go diff --git a/pkg/nebula/components/authentication/route.go b/pkg/nebula/routes/auth.go similarity index 83% rename from pkg/nebula/components/authentication/route.go rename to pkg/nebula/routes/auth.go index 42b18a7c0..336aa4eb9 100644 --- a/pkg/nebula/components/authentication/route.go +++ b/pkg/nebula/routes/auth.go @@ -1,10 +1,12 @@ -package authentication +package routes import ( "log" "github.com/labstack/echo/v4" "github.com/onsonr/sonr/internal/ctx" + "github.com/onsonr/sonr/pkg/nebula/modals" + "github.com/onsonr/sonr/pkg/nebula/views" ) // ╭───────────────────────────────────────────────────────────╮ @@ -18,7 +20,7 @@ func CurrentViewRoute(c echo.Context) error { return err } log.Printf("Session ID: %s", s.ID()) - return ctx.RenderTempl(c, CurrentView(c)) + return ctx.RenderTempl(c, views.CurrentView(c)) } // ╭───────────────────────────────────────────────────────────╮ @@ -27,15 +29,15 @@ func CurrentViewRoute(c echo.Context) error { // AuthorizeModalRoute returns the Authorize Modal route. func AuthorizeModalRoute(c echo.Context) error { - return ctx.RenderTempl(c, AuthorizeModal(c)) + return ctx.RenderTempl(c, modals.AuthorizeModal(c)) } // LoginModalRoute returns the Login Modal route. func LoginModalRoute(c echo.Context) error { - return ctx.RenderTempl(c, LoginModal(c)) + return ctx.RenderTempl(c, modals.LoginModal(c)) } // RegisterModalRoute returns the Register Modal route. func RegisterModalRoute(c echo.Context) error { - return ctx.RenderTempl(c, RegisterModal(c)) + return ctx.RenderTempl(c, modals.RegisterModal(c)) } diff --git a/pkg/nebula/routes/home.go b/pkg/nebula/routes/home.go new file mode 100644 index 000000000..c8ff70fe4 --- /dev/null +++ b/pkg/nebula/routes/home.go @@ -0,0 +1,22 @@ +package routes + +import ( + "log" + + "github.com/labstack/echo/v4" + "github.com/onsonr/sonr/internal/ctx" + "github.com/onsonr/sonr/pkg/nebula/marketing" +) + +// ╭───────────────────────────────────────────────────────────╮ +// │ Home Routes - Marketing │ +// ╰───────────────────────────────────────────────────────────╯ + +func HomeRoute(c echo.Context) error { + s, err := ctx.GetHWAYContext(c) + if err != nil { + return err + } + log.Printf("Session ID: %s", s.ID()) + return ctx.RenderTempl(c, marketing.View()) +} diff --git a/pkg/nebula/tailwind.config.js b/pkg/nebula/tailwind.config.js index 33ec812ba..15fc39803 100644 --- a/pkg/nebula/tailwind.config.js +++ b/pkg/nebula/tailwind.config.js @@ -1,6 +1,7 @@ // tailwind.config.js module.exports = { content: [ + "./**/*.{templ,html}", "./components/**/*.{templ,html}", "./global/**/*.{templ,html}", ], diff --git a/pkg/nebula/components/authentication/view.templ b/pkg/nebula/views/current.templ similarity index 95% rename from pkg/nebula/components/authentication/view.templ rename to pkg/nebula/views/current.templ index 8a646b65c..d8a8028ab 100644 --- a/pkg/nebula/components/authentication/view.templ +++ b/pkg/nebula/views/current.templ @@ -1,4 +1,4 @@ -package authentication +package views import echo "github.com/labstack/echo/v4" diff --git a/pkg/nebula/components/authentication/view_templ.go b/pkg/nebula/views/current_templ.go similarity index 98% rename from pkg/nebula/components/authentication/view_templ.go rename to pkg/nebula/views/current_templ.go index 1767d08f1..d03fbab4d 100644 --- a/pkg/nebula/components/authentication/view_templ.go +++ b/pkg/nebula/views/current_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package authentication +package views //lint:file-ignore SA4006 This context is only used if a nested component is present. diff --git a/pkg/nebula/components/vaultindex/index.templ b/pkg/nebula/views/index.templ similarity index 95% rename from pkg/nebula/components/vaultindex/index.templ rename to pkg/nebula/views/index.templ index 56c1e12c5..23250c06c 100644 --- a/pkg/nebula/components/vaultindex/index.templ +++ b/pkg/nebula/views/index.templ @@ -1,11 +1,11 @@ -package vaultindex +package views import ( "github.com/onsonr/sonr/pkg/nebula/global/state" "github.com/onsonr/sonr/pkg/nebula/global/styles" ) -templ IndexFile() { +templ VaultIndexFile() { diff --git a/pkg/nebula/components/vaultindex/index_templ.go b/pkg/nebula/views/index_templ.go similarity index 98% rename from pkg/nebula/components/vaultindex/index_templ.go rename to pkg/nebula/views/index_templ.go index 80677bafb..8127aba92 100644 --- a/pkg/nebula/components/vaultindex/index_templ.go +++ b/pkg/nebula/views/index_templ.go @@ -1,7 +1,7 @@ // Code generated by templ - DO NOT EDIT. // templ: version: v0.2.778 -package vaultindex +package views //lint:file-ignore SA4006 This context is only used if a nested component is present. @@ -13,7 +13,7 @@ import ( "github.com/onsonr/sonr/pkg/nebula/global/styles" ) -func IndexFile() templ.Component { +func VaultIndexFile() templ.Component { return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) { templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { diff --git a/pkg/workers/routes/gateway.go b/pkg/workers/routes/gateway.go index b2b43b8bd..ea02888f0 100644 --- a/pkg/workers/routes/gateway.go +++ b/pkg/workers/routes/gateway.go @@ -3,15 +3,14 @@ package routes import ( "github.com/labstack/echo/v4" - "github.com/onsonr/sonr/pkg/nebula/components/authentication" - "github.com/onsonr/sonr/pkg/nebula/components/marketing" + "github.com/onsonr/sonr/pkg/nebula/routes" ) func RegisterGatewayAPI(e *echo.Echo) { } func RegisterGatewayViews(e *echo.Echo) { - e.GET("/", marketing.HomeRoute) - e.GET("/login", authentication.LoginModalRoute) - e.GET("/register", authentication.RegisterModalRoute) + e.GET("/", routes.HomeRoute) + e.GET("/login", routes.LoginModalRoute) + e.GET("/register", routes.RegisterModalRoute) } diff --git a/pkg/workers/routes/webnode.go b/pkg/workers/routes/webnode.go index ca0955d1f..fa0cb3900 100644 --- a/pkg/workers/routes/webnode.go +++ b/pkg/workers/routes/webnode.go @@ -3,7 +3,7 @@ package routes import ( "github.com/labstack/echo/v4" - "github.com/onsonr/sonr/pkg/nebula/components/authentication" + "github.com/onsonr/sonr/pkg/nebula/routes" "github.com/onsonr/sonr/pkg/workers/handlers" ) @@ -26,8 +26,8 @@ func RegisterWebNodeAPI(e *echo.Echo) { // RegisterWebNodeViews registers the Decentralized Web Node HTMX views. func RegisterWebNodeViews(e *echo.Echo) { e.File("/", "index.html") - e.GET("/#", authentication.CurrentViewRoute) - e.GET("/login", authentication.LoginModalRoute) + e.GET("/#", routes.CurrentViewRoute) + e.GET("/login", routes.LoginModalRoute) e.File("/config", "config.json") - e.GET("/register", authentication.RegisterModalRoute) + e.GET("/register", routes.RegisterModalRoute) }