Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Our415 87 header nav base #1369

Open
wants to merge 296 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
296 commits
Select commit Hold shift + click to select a range
7546894
Merge branch 'base-style-update' of https://github.com/Exygy/askdarce…
kramduckner Jun 2, 2024
d862230
Merge branch 'main' into sanity-sync
kramduckner Jun 3, 2024
9758a02
add block-content-to-react package
kramduckner Jun 3, 2024
7c53df5
Merge branch 'base-style-update' into content-template-with-styles
kramduckner Jun 3, 2024
9f131b2
make font weight consistent of h tags
kramduckner Jun 3, 2024
1de6c82
Merge branch 'base-style-update' into content-template-with-styles
kramduckner Jun 3, 2024
fd4b54b
update font in reset.scss
kramduckner Jun 3, 2024
27a2ab9
Merge branch 'base-style-update' into content-template-with-styles
kramduckner Jun 3, 2024
c11487c
update headings styles; swap reset and helpers order
kramduckner Jun 3, 2024
4ce6a15
Merge branch 'base-style-update' into content-template-with-styles
kramduckner Jun 3, 2024
328651a
Merge pull request #21 from Exygy/base-style-update
kramduckner Jun 3, 2024
f1eac65
update base styles for about page
kramduckner Jun 3, 2024
63b05aa
update readme to include env vars
kramduckner Jun 3, 2024
0466aec
Merge pull request #23 from Exygy/update-readme
kramduckner Jun 3, 2024
2000144
improve sentence
kramduckner Jun 4, 2024
7a4899c
Merge pull request #24 from Exygy/update-readme-06-04-24
kramduckner Jun 4, 2024
f9cdb3e
improve sentence
kramduckner Jun 4, 2024
ea7fa92
Merge pull request #25 from Exygy/update-readme-06-04-24
kramduckner Jun 4, 2024
e5f7cae
improve sentence
kramduckner Jun 4, 2024
f33e24d
update sanity config to use env vars
kramduckner Jun 4, 2024
cfa7730
update readme
kramduckner Jun 4, 2024
930700b
Merge branch 'development' into update-readme-06-04-24
kramduckner Jun 4, 2024
558d5e4
Merge pull request #26 from Exygy/update-readme-06-04-24
kramduckner Jun 4, 2024
2a2d63f
add new footer logos
adriencyberspace Jun 4, 2024
f6231b8
save old footer for reference and start new one
adriencyberspace Jun 4, 2024
5247701
footer desktop structure and styles
adriencyberspace Jun 4, 2024
08729ab
fetch footer sanity data (having issues)
adriencyberspace Jun 4, 2024
36b9ac7
npm install having issues
adriencyberspace Jun 4, 2024
2d421ae
add correct dependencies
adriencyberspace Jun 5, 2024
4a481ce
fetch sanity footer data and render address section
adriencyberspace Jun 5, 2024
578ac40
footer pulls all data from sanity
adriencyberspace Jun 5, 2024
b3250c2
refactor Footer components into a dir
adriencyberspace Jun 5, 2024
83e11fe
refactor helper functions out of Footer and into utils files
adriencyberspace Jun 5, 2024
87e30cd
mobile styles
adriencyberspace Jun 5, 2024
d247e07
replace small logos with higher res
adriencyberspace Jun 5, 2024
f7a50fc
add margin left to columns on desktop
adriencyberspace Jun 5, 2024
e3abf18
add image support; style new components
kramduckner Jun 5, 2024
1154963
add sanity config
kramduckner Jun 5, 2024
a8f5c12
prettier warning
adriencyberspace Jun 5, 2024
2b8debe
lint errors
adriencyberspace Jun 5, 2024
cbecc35
add focus states to the links
adriencyberspace Jun 6, 2024
8dc91b1
make font weight consistent of h tags
kramduckner Jun 3, 2024
7ec27bf
update font in reset.scss
kramduckner Jun 3, 2024
168b989
update headings styles; swap reset and helpers order
kramduckner Jun 3, 2024
1118133
update readme to include env vars
kramduckner Jun 3, 2024
c1de35d
improve sentence
kramduckner Jun 4, 2024
53d9d8f
improve sentence
kramduckner Jun 4, 2024
3158e96
improve sentence
kramduckner Jun 4, 2024
bbd64a0
update readme
kramduckner Jun 4, 2024
a97fcd0
update to use tokens; styling pass
kramduckner Jun 7, 2024
4509dec
clean up scss, remove bottom margin on p tags, add typings for block …
kramduckner Jun 8, 2024
16aaedb
Merge branch 'development' into content-template-with-styles
kramduckner Jun 9, 2024
384be7a
replace old about page
kramduckner Jun 9, 2024
64898d4
Merge branch 'content-template-with-styles' of https://github.com/Exy…
kramduckner Jun 9, 2024
dfb6a91
run prettier
kramduckner Jun 9, 2024
17df130
revert changes to h2
kramduckner Jun 9, 2024
07f0567
create hero and styles, not yet using Button component or pulling fro…
adriencyberspace Jun 9, 2024
6107994
integrate sanity; add test api call
kramduckner May 23, 2024
a5c8e95
add new about page
kramduckner May 24, 2024
793e453
add Masthead, EmailSignup, and AboutPage components
kramduckner May 28, 2024
5845d0b
add block-content-to-react package
kramduckner Jun 3, 2024
090d7bb
update base styles for about page
kramduckner Jun 3, 2024
ada5383
update sanity config to use env vars
kramduckner Jun 4, 2024
614e330
add image support; style new components
kramduckner Jun 5, 2024
4c966e7
add sanity config
kramduckner Jun 5, 2024
152ae52
update to use tokens; styling pass
kramduckner Jun 7, 2024
679f21e
clean up scss, remove bottom margin on p tags, add typings for block …
kramduckner Jun 8, 2024
83c8662
replace old about page
kramduckner Jun 9, 2024
8905a76
run prettier
kramduckner Jun 9, 2024
5f5001b
revert changes to h2
kramduckner Jun 9, 2024
7b271f8
Merge branch 'content-template-with-styles' of https://github.com/Exy…
kramduckner Jun 10, 2024
148bc6a
fix tyescript and lint errors
kramduckner Jun 10, 2024
dcd648e
init sanity client and image builder
jtcaovan Jun 10, 2024
6f2ceb9
create event card section
jtcaovan Jun 10, 2024
c29666d
create event card and date helper function
jtcaovan Jun 10, 2024
d666eb4
Merge branch 'development' into #128-opp-card-section
jtcaovan Jun 10, 2024
7900a08
use spacing vars and query the main footer specifically
adriencyberspace Jun 10, 2024
eb57251
Merge branch 'development' into footer
adriencyberspace Jun 10, 2024
686c4b2
Merge pull request #27 from Exygy/footer
adriencyberspace Jun 10, 2024
9687c92
mobile styling and vars
adriencyberspace Jun 10, 2024
f1f70c7
import font awesome to use in css
adriencyberspace Jun 10, 2024
8bfc0c4
tweak background image styling
adriencyberspace Jun 10, 2024
b4c2b89
refactor date/time component
jtcaovan Jun 10, 2024
c4ab8d7
resolve merge conflicts
jtcaovan Jun 10, 2024
94e1b98
fix prettier errors
jtcaovan Jun 10, 2024
b373d63
Merge branch 'development' into home-hero
adriencyberspace Jun 10, 2024
4130991
add sanity packages (something not working)
adriencyberspace Jun 10, 2024
2a03ab9
update Hero and HomePage to use sanity data (except image)
adriencyberspace Jun 10, 2024
7024574
fix types
adriencyberspace Jun 10, 2024
593f702
use imageUrlBuild
adriencyberspace Jun 10, 2024
d88cbc8
address lint errors
adriencyberspace Jun 10, 2024
718d455
add sanity config to support viewing drafts for staging
kramduckner Jun 11, 2024
fa7226a
add sanity api key message
kramduckner Jun 11, 2024
a8718b7
Merge pull request #31 from Exygy/sanity-environment
kramduckner Jun 11, 2024
c146aaa
add env vars to deploy workflow
kramduckner Jun 11, 2024
5fb991a
fix yml error
kramduckner Jun 11, 2024
19757da
Merge pull request #32 from Exygy/sanity-environment
kramduckner Jun 11, 2024
1f72121
change styling to match themes, fix setisloading issue
jtcaovan Jun 11, 2024
1c8db42
fix prettier issue
jtcaovan Jun 11, 2024
e3db87a
update spacing css variables
jtcaovan Jun 11, 2024
d45d608
Merge pull request #29 from Exygy/#128-opp-card-section
jtcaovan Jun 11, 2024
0e832d6
max-width of 568px but maintain left edge at same point as rest of co…
adriencyberspace Jun 11, 2024
ea60458
Merge branch 'development' into home-hero
adriencyberspace Jun 11, 2024
350eb33
Merge pull request #30 from Exygy/home-hero
adriencyberspace Jun 11, 2024
09c8e6e
new button with primary and secondary variants
adriencyberspace Jun 11, 2024
2b68e5a
replace placeholder buttons with new button component
adriencyberspace Jun 11, 2024
7b6519d
placeholder button section to test buttons
adriencyberspace Jun 11, 2024
29b588a
add mobileFullWidth prop and use color vars
adriencyberspace Jun 11, 2024
7bc5b3c
add linkBlue and linkWhite variants to homepage temp section
adriencyberspace Jun 11, 2024
fa122a2
add css for linkWhite and linkBlue plus scss vars
adriencyberspace Jun 11, 2024
234eb40
lint errors
adriencyberspace Jun 12, 2024
df2ae95
add comments
adriencyberspace Jun 12, 2024
fbffb93
Remove expander toggle button and state
adriencyberspace Jun 12, 2024
8931d3f
remove expanded state and auth state and comment out modals
adriencyberspace Jun 12, 2024
8d2274f
remove css for deleted section
adriencyberspace Jun 12, 2024
7b9beb1
remove unused modals and comment out texting code for phase 2 use
adriencyberspace Jun 12, 2024
328c419
Style card according to mockup (awaiting button pr merge)
adriencyberspace Jun 12, 2024
93e2a7d
general surrounding styling so card can be styled properly
adriencyberspace Jun 12, 2024
e05dacd
style edits to listing card
adriencyberspace Jun 12, 2024
ed41567
rm redundant package
adriencyberspace Jun 12, 2024
ed4e5be
comment out categoryId because we may need it soon
adriencyberspace Jun 12, 2024
a4611a1
out of scope but there are no focus states on the entire site so adde…
adriencyberspace Jun 12, 2024
5842090
mobile styling on listing card
adriencyberspace Jun 12, 2024
c915696
refactor utils helpers and texting comments into separate file for la…
adriencyberspace Jun 12, 2024
161ee8e
minor styling tweaks to pagination
adriencyberspace Jun 13, 2024
bcda515
Merge pull request #33 from Exygy/button-styles
adriencyberspace Jun 13, 2024
a8057d6
Remove temp code from buttons pr
adriencyberspace Jun 13, 2024
0ae77bd
Merge branch 'development' into listing-card
adriencyberspace Jun 13, 2024
4484469
remove unecessary lines that snuck in from prior pr
adriencyberspace Jun 13, 2024
f54fa43
hover state to icon link
adriencyberspace Jun 13, 2024
5598f58
revert changes out of scope
adriencyberspace Jun 13, 2024
d29b53d
remove css for classes that are no longer being used
adriencyberspace Jun 13, 2024
39186e3
keep the commented out texting feature in same component
adriencyberspace Jun 13, 2024
6f83d8b
change pagination bg color
adriencyberspace Jun 13, 2024
814e6e4
flip phone icon
adriencyberspace Jun 13, 2024
c10f8f7
change content widths and add vars
adriencyberspace Jun 13, 2024
8ede8cf
remove reset
adriencyberspace Jun 13, 2024
361e667
update css vars to scss; update any type; update tablet bp; make btn …
kramduckner Jun 13, 2024
b8d7466
resolve merge conflict
kramduckner Jun 13, 2024
f7e3e86
remove unused button
kramduckner Jun 13, 2024
2c414b9
Merge pull request #28 from Exygy/content-template-with-styles
kramduckner Jun 13, 2024
90a4f3b
add outline states
adriencyberspace Jun 14, 2024
df38e73
remove NewsArticles causing screen reader confusion
adriencyberspace Jun 14, 2024
97af95b
temp fix so screen reader doesn't read mobile nav links on desktop
adriencyberspace Jun 14, 2024
4f3b2d8
rounded buttons should have round outlines
adriencyberspace Jun 14, 2024
186b20b
Merge branch 'development' into style-fixes
adriencyberspace Jun 14, 2024
8b3fcbe
add comments for clarity
adriencyberspace Jun 14, 2024
8d3c4b9
Merge branch 'style-fixes' of https://github.com/Exygy/askdarcel-web …
adriencyberspace Jun 14, 2024
57300e1
fix lint error
adriencyberspace Jun 14, 2024
f582265
fix lint error
adriencyberspace Jun 14, 2024
b4df1c4
Merge pull request #38 from Exygy/style-fixes
adriencyberspace Jun 17, 2024
aa1d74f
Update app/utils/numbers.ts
adriencyberspace Jun 17, 2024
534295b
Merge branch 'development' into listing-card
adriencyberspace Jun 17, 2024
15f72ce
add sanity image-url dependency again
adriencyberspace Jun 17, 2024
daaadcd
run prettier
adriencyberspace Jun 17, 2024
da1a976
Merge pull request #34 from Exygy/listing-card
adriencyberspace Jun 17, 2024
cc184a3
Newsletter signup recaptcha test (#40)
adriencyberspace Jun 17, 2024
6d15d10
Revert "Newsletter signup recaptcha test (#40)" (#41)
adriencyberspace Jun 17, 2024
6d4d8c5
update resolver dns ip
kramduckner Jun 18, 2024
c5f54ec
update font awesome version
jtcaovan Jun 13, 2024
9a05ea8
create category card section and cards
jtcaovan Jun 13, 2024
19a3218
address adriens pr comments
jtcaovan Jun 14, 2024
4690ced
fix prettier issue
jtcaovan Jun 14, 2024
d7a808f
rm title/description for future pr
jtcaovan Jun 19, 2024
2381236
update active/focus color
jtcaovan Jun 19, 2024
f579684
fix prettier
jtcaovan Jun 19, 2024
528a762
add documentation
jtcaovan Jun 19, 2024
9f537af
Merge pull request #44 from Exygy/category-cards-clean
jtcaovan Jun 20, 2024
427940d
Merge pull request #42 from Exygy/update-v2-api-config
kramduckner Jun 20, 2024
2458f1e
initial home page prep
jtcaovan Jun 13, 2024
7e75cb8
move and export type from two column component
jtcaovan Jun 18, 2024
1ad45f1
create 2 column component for home page
jtcaovan Jun 18, 2024
b596294
rm resource count state
jtcaovan Jun 18, 2024
bb7a42f
refactor into one api call from sanity
jtcaovan Jun 18, 2024
19564ca
connect oppevent cards to sanity data
jtcaovan Jun 18, 2024
2bfb53d
fix button issue with two column content, misc changes
jtcaovan Jun 18, 2024
63eef68
refactor home page section component
jtcaovan Jun 19, 2024
c8d2fe4
add focus/active state on event cards
jtcaovan Jun 19, 2024
32a4e1a
refactor event section to use home page section
jtcaovan Jun 19, 2024
61b8175
fix small breakpoint issue with two column section
jtcaovan Jun 19, 2024
71efed6
fix prettier
jtcaovan Jun 19, 2024
d94ecb8
fix build error
jtcaovan Jun 19, 2024
2470d9c
fix build errors again
jtcaovan Jun 19, 2024
d56197a
add in category cards
jtcaovan Jun 20, 2024
db63bdd
fetch home page 2 column content
jtcaovan Jun 20, 2024
2e325c0
fix slug type
jtcaovan Jun 20, 2024
962927d
rm console.log
jtcaovan Jun 20, 2024
c893886
fix two column types
jtcaovan Jun 20, 2024
3f4366e
fix prettier/lint issues
jtcaovan Jun 20, 2024
dc3aaef
refactor see all services icon
jtcaovan Jun 20, 2024
548aea7
add v2 to proxy pass for v2 routes
kramduckner Jun 20, 2024
a044655
Merge pull request #45 from Exygy/update-v2-api-config
kramduckner Jun 20, 2024
9621c05
update v2 proxy pass 1:1 to v1 (omit /api/)
kramduckner Jun 20, 2024
b4fec91
Merge pull request #46 from Exygy/update-v2-api-config
kramduckner Jun 20, 2024
9d789f8
update comments, address pr review comments
jtcaovan Jun 21, 2024
72ad471
add basic error handling
jtcaovan Jun 21, 2024
0a8b8a7
fix no console lint error, revert two column prop type
jtcaovan Jun 21, 2024
9660204
rm previous global button styling
jtcaovan Jun 21, 2024
7fb276c
Merge pull request #37 from Exygy/home-page-prep
jtcaovan Jun 21, 2024
2e3f5d5
Service page (#48)
adriencyberspace Jun 24, 2024
8b57e34
Search Results section and related fixes (#52)
adriencyberspace Jun 25, 2024
f9f65be
Adds `SecondaryNavigationLayout` and `BackNavigation` component (#50)
rosschapman Jun 25, 2024
40d03b2
Adds vscode gitignore directives (#49)
rosschapman Jun 25, 2024
6950d8a
Long description fixes (#53)
adriencyberspace Jun 25, 2024
419081a
replaces footer with content from Strapi (#54)
seanmalbert Jun 26, 2024
fd7cb2c
Create base
rosschapman Jun 27, 2024
033438c
[OUR415-87] Decouples `<SiteSearch />` from `<Navigation />` (#55)
rosschapman Jun 27, 2024
1f2ed57
Loader component (#63)
adriencyberspace Jun 27, 2024
40546d2
create new breakpoint to fit map
jtcaovan Jun 27, 2024
72e4031
new map styling - button and height
jtcaovan Jun 27, 2024
071628c
add border and fix padding small breakpoint, fix lint
jtcaovan Jun 28, 2024
08f584e
Hardcoded categories on homepage (#62)
adriencyberspace Jul 1, 2024
db6f385
edit marker colors
adriencyberspace Jul 1, 2024
941f7a7
Hardcoded categories on homepage (#62)
adriencyberspace Jul 1, 2024
e6257e1
update print button styling, clean unused map button props
jtcaovan Jul 1, 2024
b8db812
Merge pull request #64 from Exygy/listing-map
jtcaovan Jul 1, 2024
785df46
Search card subcategories (#57)
adriencyberspace Jul 1, 2024
12f1257
add our415 favicon and icon to header
jtcaovan Jul 1, 2024
f5442d5
fix favicon typo
jtcaovan Jul 1, 2024
961518c
update backnavigation component and routing
jtcaovan Jul 1, 2024
23a13c9
reverts logo changes
jtcaovan Jul 1, 2024
d95822a
fix lint issues
jtcaovan Jul 1, 2024
c87a422
Separates api response types from model types (#61)
rosschapman Jul 1, 2024
30bb8ab
pass in text as children
jtcaovan Jul 1, 2024
ab0c03d
Merge pull request #66 from Exygy/service-header
jtcaovan Jul 1, 2024
62c4950
Merge branch 'development' into OUR415-87-header-nav-base
rosschapman Jul 1, 2024
7f22644
Filter dropdown (#67)
adriencyberspace Jul 1, 2024
82d0e00
Merge branch 'OUR415-87-header-nav-base' of github.com:Exygy/askdarce…
rosschapman Jul 1, 2024
67a3bba
Merge branch 'development' into OUR415-87-header-nav-base
rosschapman Jul 1, 2024
afd2c1d
Org page for demo (#68)
adriencyberspace Jul 1, 2024
48d0a17
hotfix homepage styles for demo
adriencyberspace Jul 1, 2024
a69041e
hotfix header styles for demo
adriencyberspace Jul 1, 2024
605329c
hotfix section styling for demo
adriencyberspace Jul 1, 2024
e1a6e8e
hotfix h2 org page for demo
adriencyberspace Jul 1, 2024
a947455
hotfix remove global section styling for demo
adriencyberspace Jul 1, 2024
ad188cd
Adds component markup for logo and dropdown menus using Strapi data f…
rosschapman Jul 2, 2024
0b6c0ce
Fixes formatting
rosschapman Jul 2, 2024
1d8a879
ListingInfoSection for Service and Organization listing pages (#71)
adriencyberspace Jul 2, 2024
cbe7aef
Adds styling to NavigationMenu component on desktop (#69)
rosschapman Jul 3, 2024
c687a68
Listing page layout (#73)
adriencyberspace Jul 3, 2024
1525ad1
[OUR415-87] Consolidates desktop and mobile navigation components (#72)
rosschapman Jul 5, 2024
fe6b76b
Merge branch 'development' into OUR415-87-header-nav-base
rosschapman Jul 8, 2024
33f16a6
Listing table (#74)
adriencyberspace Jul 8, 2024
02a7467
Replaces Sanity with Strapi (#70)
seanmalbert Jul 8, 2024
956d191
Askdarcel Staging API (#77)
seanmalbert Jul 10, 2024
ec4e4b2
Listing page tags (#76)
adriencyberspace Jul 10, 2024
776e59f
Adds conditional rendering for top level link and refactors Mobile an…
rosschapman Jul 10, 2024
e310eed
Merge branch 'development' into OUR415-87-header-nav-base
rosschapman Jul 10, 2024
28a2f93
Updates null checking
rosschapman Jul 10, 2024
6b9ab93
Fixes linting
rosschapman Jul 10, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ module.exports = {
"no-underscore-dangle": "off",
"react-hooks/exhaustive-deps": "error", // Default is 'warn'; we upgrade to 'error' because otherwise warnings are just noise
"react/forbid-prop-types": "off",
"react/no-danger": "off",
"react/prefer-stateless-function": "off",
"react/prop-types": "off",
"react/jsx-filename-extension": ["error", { extensions: [".tsx"] }],
Expand Down Expand Up @@ -69,7 +70,10 @@ module.exports = {
"@typescript-eslint/no-unsafe-call": "off",
"@typescript-eslint/no-unsafe-member-access": "off",
"@typescript-eslint/no-unsafe-return": "off",
"@typescript-eslint/no-unused-vars": "error",
"@typescript-eslint/no-unused-vars": [
"error",
{ ignoreRestSiblings: true },
],
"@typescript-eslint/no-unused-expressions": "error",
"@typescript-eslint/require-await": "off",
"@typescript-eslint/restrict-template-expressions": "off",
Expand Down
48 changes: 48 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Build, lint and run unit tests.

on:
pull_request:
branches: [main, development]

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ env.NODE_VERSION }}
- uses: actions/cache@v2
with:
path: ~/.npm
key: npm-${{ hashFiles('package-lock.json') }}
restore-keys: npm-
- run: npm i
- run: npm run prettier
- run: npm run lint
build_and_test_app:
runs-on: ubuntu-latest
environment: "dev"
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ env.NODE_VERSION }}
- uses: actions/cache@v2
with:
path: ~/.npm
key: npm-${{ hashFiles('package-lock.json') }}
restore-keys: npm-
- run: npm i
- run: npm run test
- run: npm run build
env:
AUTH0_DOMAIN: ${{ secrets.AUTH0_DOMAIN }}
AUTH0_CLIENT_ID: ${{ secrets.AUTH0_CLIENT_ID }}
AUTH0_AUDIENCE: ${{ secrets.AUTH0_AUDIENCE }}
AUTH0_REDIRECT_URI: ${{ secrets.AUTH0_REDIRECT_URI }}
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
ALGOLIA_INDEX_PREFIX: ${{ secrets.ALGOLIA_INDEX_PREFIX }}
ALGOLIA_APPLICATION_ID: ${{ secrets.ALGOLIA_APPLICATION_ID }}
ALGOLIA_READ_ONLY_API_KEY: ${{ secrets.ALGOLIA_READ_ONLY_API_KEY }}
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
# Exygy - This is a workflow from Sheltertech that we don't use in the fork

name: testsuite

Expand Down
45 changes: 45 additions & 0 deletions .github/workflows/deploy-development.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Build and deploy to heroku staging.

on:
push:
branches: [development]

jobs:
build_and_deploy_app:
runs-on: ubuntu-latest
environment: "dev"
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ env.NODE_VERSION }}
- uses: actions/cache@v2
with:
path: ~/.npm
key: npm-${{ hashFiles('package-lock.json') }}
restore-keys: npm-
- run: npm i
- run: npm run test
- run: npm run build
env:
AUTH0_DOMAIN: ${{ secrets.AUTH0_DOMAIN }}
AUTH0_CLIENT_ID: ${{ secrets.AUTH0_CLIENT_ID }}
AUTH0_AUDIENCE: ${{ secrets.AUTH0_AUDIENCE }}
AUTH0_REDIRECT_URI: ${{ secrets.AUTH0_REDIRECT_URI }}
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
ALGOLIA_INDEX_PREFIX: ${{ secrets.ALGOLIA_INDEX_PREFIX }}
ALGOLIA_APPLICATION_ID: ${{ secrets.ALGOLIA_APPLICATION_ID }}
ALGOLIA_READ_ONLY_API_KEY: ${{ secrets.ALGOLIA_READ_ONLY_API_KEY }}
STRAPI_API_TOKEN: ${{ secrets.STRAPI_API_TOKEN }}
STRAPI_API_URL: ${{ secrets.STRAPI_API_URL }}
- name: Build, Push and Release a Docker container to Heroku.
uses: gonuit/[email protected]
with:
email: ${{ secrets.HEROKU_EMAIL }}
heroku_api_key: ${{ secrets.HEROKU_API_KEY }}
heroku_app_name: ${{ secrets.HEROKU_APP_NAME }}
dockerfile_directory: ./
dockerfile_name: Dockerfile
docker_options: "--no-cache"
process_type: web
43 changes: 43 additions & 0 deletions .github/workflows/deploy-production.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Build and deploy to heroku production.

on:
push:
branches: [main]

jobs:
build_and_deploy_app:
runs-on: ubuntu-latest
environment: "prod"
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ env.NODE_VERSION }}
- uses: actions/cache@v2
with:
path: ~/.npm
key: npm-${{ hashFiles('package-lock.json') }}
restore-keys: npm-
- run: npm i
- run: npm run test
- run: npm run build
env:
AUTH0_DOMAIN: ${{ secrets.AUTH0_DOMAIN }}
AUTH0_CLIENT_ID: ${{ secrets.AUTH0_CLIENT_ID }}
AUTH0_AUDIENCE: ${{ secrets.AUTH0_AUDIENCE }}
AUTH0_REDIRECT_URI: ${{ secrets.AUTH0_REDIRECT_URI }}
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
ALGOLIA_INDEX_PREFIX: ${{ secrets.ALGOLIA_INDEX_PREFIX }}
ALGOLIA_APPLICATION_ID: ${{ secrets.ALGOLIA_APPLICATION_ID }}
ALGOLIA_READ_ONLY_API_KEY: ${{ secrets.ALGOLIA_READ_ONLY_API_KEY }}
- name: Build, Push and Release a Docker container to Heroku.
uses: gonuit/[email protected]
with:
email: ${{ secrets.HEROKU_EMAIL }}
heroku_api_key: ${{ secrets.HEROKU_API_KEY }}
heroku_app_name: ${{ secrets.HEROKU_APP_NAME }}
dockerfile_directory: ./
dockerfile_name: Dockerfile
docker_options: "--no-cache"
process_type: web
1 change: 1 addition & 0 deletions .github/workflows/publish-qa.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Exygy - This is a workflow from Sheltertech that we don't use in the fork
name: publish-qa

on:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Exygy - This is a workflow from Sheltertech that we don't use in the fork
name: publish-release

on:
Expand Down
13 changes: 13 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,16 @@ yarn.lock

cypress/videos/**
cypress/screenshots/**

.vscode/*
# !.vscode/settings.json
# !.vscode/tasks.json
# !.vscode/launch.json
# !.vscode/extensions.json
# !.vscode/*.code-snippets

# Local History for Visual Studio Code
.history/

# Built Visual Studio Code Extensions
*.vsix
12 changes: 5 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
FROM nginx:stable

RUN apt-get update && apt-get -y install ruby && gem install tiller
WORKDIR /app/askdarcel

COPY build /app/askdarcel
COPY version.json /app/askdarcel/_version.json
COPY tools/replace-environment-config.sh /app/askdarcel
# Copy build files
COPY ./build /app/askdarcel

RUN rm /etc/nginx/conf.d/*

ADD docker/tiller /etc/tiller
COPY ./docker/templates/default.conf.template /etc/nginx/templates/default.conf.template

CMD ["tiller", "-v"]
ENTRYPOINT ["/app/askdarcel/replace-environment-config.sh", "/app/askdarcel/bundle.js"]
CMD ["nginx", "-g", "daemon off;"]
26 changes: 16 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
# ShelterTech Web App [![Travis CI Status](https://travis-ci.org/ShelterTechSF/askdarcel-web.svg?branch=master)](https://travis-ci.org/ShelterTechSF/askdarcel-web)

## Sauce Labs Browser Test Status

[![Sauce Test Status](https://saucelabs.com/browser-matrix/askdarcel-web-master.svg)](https://saucelabs.com/u/askdarcel-web-master)

## Onboarding Instructions

[Dev Role Description](https://www.notion.so/sheltertech/Developer-Engineer-Role-Description-ShelterTech-AskDarcel-SFServiceGuide-Tech-Team-7fd992a20f864698a43e3882a66338bb)

[Technical Onboarding & Team Guidelines](https://www.notion.so/sheltertech/Technical-Onboarding-and-Team-Guidelines-a06d5543495248bfb6f17e233330249e)

## Docker-based Development Environment (Recommended)

### Requirements
Expand Down Expand Up @@ -155,3 +145,19 @@ $ docker-compose run --rm -p 1337:1337 -e BASE_URL=http://web:8080 web npm run t
```

This will spin up a web server at http://localhost:1337/ and print out a URL to use. You should manually enter it into your browser to start the tests.

## Branches and Deployments

There are two protected branches - development and main. Main is the default branch which will be the latest, stable codebase. Development will be where updates get deployed to a staging instance where QA can be performed. Any PR's created against these branches run a series of checks - like building the app, running unit tests, and linting the files.

There are two live instances - a [staging instance](https://our415-staging-a91cdc6d7b2b.herokuapp.com/) and a [production instance](https://our415-abb7eecb7449.herokuapp.com/). Merges onto the development branch deploys the development branch to the staging isntance. Merges onto the main branch deploys the main branch to the production instance. See the [github workflows](https://github.com/Exygy/askdarcel-web/tree/main/.github/workflows) for the details. Environment variables used in the deployments are set in github environments - 'prod' supplies the production instance and 'dev' supplies the staging instance..

## Pull Requests

Pull requests are opened to the development branch. When opening a pull request please fill out the as much of the pull request template you can, which includes tagging the issue your PR is related to, a description of your PR, indicating the type of change, including details for the reviewer about how to test your PR, and a testing checklist. Additionally, officially link the notion ticket to the PR using GitHub's linking UI.

When your PR is ready for review, add the needs review(s) label to help surface it to the other devs. You can assign people as reviewers to surface the work further. If you put up a PR that is not yet ready for eyes, add the wip label.

Once the PR has been approved, you either (1) squash and merge the commits if your changes are just in one package, or (2) rebase and merge your commits if your commits are cleanly separated across multiple packages to allow the versions to propagate appropriately.

As a reviewer on a PR, try not to leave only comments, but a clear next step action. If the PR requires further discussion or changes, mark it with Requested Changes. If a PR looks good to you (or even if there are small changes requested that won't require an additional review), please mark it with Approved and comment on the last few changes needed. This helps other reviewers better understand the state of PRs at the list view and prevents an additional unnecessary review cycle.
2 changes: 2 additions & 0 deletions app/App.module.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@import "~styles/utils/_helpers.scss";

.outerContainer {
/* Creates a stacking context such that everything inside of the
* .outerContainer is either above or below anything outside of the
Expand Down
58 changes: 9 additions & 49 deletions app/App.tsx
Original file line number Diff line number Diff line change
@@ -1,54 +1,34 @@
import React, { useEffect, useState } from "react";

// Todo: Once GA sunsets the UA analytics tracking come July 2023, we can remove the "react-ga"
// package and all references to it:
// https://support.google.com/analytics/answer/12938611#zippy=%2Cin-this-article
import ReactGA from "react-ga";
import ReactGA_4 from "react-ga4";

import Intercom from "react-intercom";
import { Helmet } from "react-helmet-async";
import { useHistory } from "react-router-dom";

import { GeoCoordinates, getLocation, whiteLabel, AppProvider } from "./utils";
import {
Banner,
HamburgerMenu,
Navigation,
PopUpMessage,
PopupMessageProp,
UserWay,
} from "./components/ui";

import { Router } from "./Router";
import { Navigation, UserWay } from "./components/ui";

import config from "./config";
import MetaImage from "./assets/img/sfsg-preview.png";

import styles from "./App.module.scss";

const { intercom, showBanner, showSearch, siteUrl, title, userWay } =
whiteLabel;
const outerContainerId = "outer-container";
const pageWrapId = "page-wrap";
const { intercom, siteUrl, title, userWay } = whiteLabel;
export const OUTER_CONTAINER_ID = "outer-container";

export const App = () => {
const history = useHistory();
const [hamburgerOpen, setHamburgerOpen] = useState(false);
const [popUpMessage, setPopUpMessage] = useState<PopupMessageProp>({
message: "",
visible: false,
type: "success",
});
const [userLocation, setUserLocation] = useState<GeoCoordinates | null>(null);

useEffect(() => {
getLocation().then((loc) => {
setUserLocation(loc);
});

ReactGA.initialize(config.GOOGLE_ANALYTICS_ID);
ReactGA_4.initialize(config.GOOGLE_ANALYTICS_GA4_ID);
if (config.GOOGLE_ANALYTICS_GA4_ID) {
ReactGA_4.initialize(config.GOOGLE_ANALYTICS_GA4_ID);
}

return history.listen((loc) => {
setTimeout(() => {
/* We call setTimeout here to give our views time to update the document title before
Expand All @@ -59,15 +39,12 @@ export const App = () => {
hitType: "pageview",
page,
});

ReactGA.set({ page });
ReactGA.pageview(page);
}, 500);
});
}, [history]);

return (
<div id={outerContainerId} className={styles.outerContainer}>
<div id={OUTER_CONTAINER_ID} className={styles.outerContainer}>
<AppProvider userLocation={userLocation}>
<Helmet>
<title>{title}</title>
Expand All @@ -90,24 +67,7 @@ export const App = () => {
{intercom && config.INTERCOM_APP_ID && (
<Intercom appID={config.INTERCOM_APP_ID} />
)}
<HamburgerMenu
isOpen={hamburgerOpen}
outerContainerId={outerContainerId}
onStateChange={(s) => setHamburgerOpen(s.isOpen)}
pageWrapId={pageWrapId}
toggleHamburgerMenu={() => setHamburgerOpen(!hamburgerOpen)}
/>
<div id={pageWrapId}>
<Navigation
showSearch={showSearch}
toggleHamburgerMenu={() => setHamburgerOpen(!hamburgerOpen)}
/>
{showBanner && <Banner />}
<div className="container">
<Router setPopUpMessage={setPopUpMessage} />
</div>
{popUpMessage && <PopUpMessage popUpMessage={popUpMessage} />}
</div>
<Navigation />
</AppProvider>
</div>
);
Expand Down
Loading