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

Staging to Production #1456

Merged
merged 39 commits into from
Nov 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
88b971c
phases start & end
jdonis Aug 9, 2024
82b060e
Dependencies: row 5 #1358
kkrug Aug 8, 2024
6a9d5d8
yarn update assets
jdonis Aug 9, 2024
1b0007f
Non gov-mil users
jdonis Aug 13, 2024
ff54f74
Merge branch 'production' into staging
kkrug Aug 13, 2024
e59c7ac
Update jquery to 3.7.1
kkrug Aug 21, 2024
7caac94
Merge branch 'staging' into 1359-update-jquery
kkrug Aug 21, 2024
c22b5bf
Merge branch '1359-update-jquery' of github.com:GSA/Challenge_gov int…
jdonis Aug 22, 2024
cb8c3ad
Update jquery to 3.7.1
kkrug Aug 21, 2024
0a78939
Revert "Update jquery to 3.7.1"
kkrug Aug 22, 2024
ad88c57
Merge pull request #1415 from GSA/revert-1412-1359-update-jquery
kkrug Aug 22, 2024
22821b5
New yarn.lock
jdonis Aug 23, 2024
1f9bc0b
remove code non-gov
jdonis Aug 23, 2024
bf5a77a
Merge branch 'staging' into 1359-update-jquery
jdonis Aug 23, 2024
f4eea8a
Merge pull request #1416 from GSA/1359-update-jquery
kkrug Aug 23, 2024
c2cfc4d
dependency diverge 3.4 -> 3.9.2
jdonis Aug 23, 2024
8e3a605
non-gov validation, logs and testing
jdonis Aug 26, 2024
f018f25
fix testing
jdonis Aug 26, 2024
2a8c25e
Merge branch 'staging' into jdonis/1390-non-gov-access
jdonis Aug 26, 2024
8feb930
closing if
jdonis Aug 26, 2024
1c9c1b7
merge if/end issues
jdonis Aug 26, 2024
bd0257a
Merge pull request #1419 from GSA/jdonis/1390-non-gov-access
kkrug Aug 27, 2024
f22338d
NG can't submit or create new Challenges
jdonis Sep 10, 2024
bc5d034
NG can't submit or create new Challenges
jdonis Sep 10, 2024
6b48e4d
Code scanning - DOM text reinterpreted as HTML #1427
kkrug Sep 16, 2024
e963b8b
Code scanning - DOM text reinterpreted as HTML #1427
kkrug Sep 17, 2024
aeee333
Code scanning - DOM text reinterpreted as HTML #1427
kkrug Sep 17, 2024
cc1fa08
Code scanning - DOM text reinterpreted as HTML #1427
kkrug Sep 18, 2024
6bb10fa
javascript console errors - challenge.gov #1434
kkrug Sep 23, 2024
3c139a6
Revert "javascript console errors - challenge.gov #1434"
jdonis Oct 14, 2024
27ae7cd
Merge pull request #1446 from GSA/revert-1436-1434-js-console-errors
jdonis Oct 14, 2024
dbf7bbc
Validation access non-gov
jdonis Oct 14, 2024
ffa569f
Merge branch 'staging' into jdonis/1390-non-gov-access
jdonis Oct 14, 2024
83ac80f
Merge pull request #1447 from GSA/jdonis/1390-non-gov-access
kkrug Oct 15, 2024
c1999e9
Footer for logged in users only - V1
jairoanaya Oct 21, 2024
1a5f7e7
Merge branch 'staging' into 1363-challenge-portal-footer
kkrug Oct 22, 2024
cb468ea
Merge pull request #1450 from GSA/1363-challenge-portal-footer
kkrug Oct 22, 2024
fd5a8b5
Revert "1363 challenge portal footer"
kkrug Oct 23, 2024
90729e6
Merge pull request #1455 from GSA/revert-1450-1363-challenge-portal-f…
kkrug Oct 23, 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: 3 additions & 3 deletions assets/client/src/components/ChallengeDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ export const ChallengeDetails = ({challenge, challengePhases, preview, print, ta
<div className="follow-tooltip__section">
<h4>Follow challenge as guest</h4>
<p>Receive challenge updates to your email. No sign-in required</p>
<a href={preview ? null : challenge.gov_delivery_topic_subscribe_link}>
<a href={preview ? "#" : `${encodeURIComponent(challenge.gov_delivery_topic_subscribe_link)}`}>
<button className="follow-tooltip__button">Follow challenge</button>
</a>
</div>
Expand Down Expand Up @@ -350,7 +350,7 @@ export const ChallengeDetails = ({challenge, challengePhases, preview, print, ta
<div className="logos">
<img
className="agency-logo"
src={imageBase + challenge.agency_logo}
src={`${imageBase}${encodeURIComponent(challenge.agency_logo)}`}
alt={`Agency logo for ${challenge.agency_name}`}
/>

Expand Down Expand Up @@ -404,7 +404,7 @@ export const ChallengeDetails = ({challenge, challengePhases, preview, print, ta
</div>
}
{!print &&
<a className="follow__btn" href={apiUrl + `/public/previews/challenges?challenge=${challenge.uuid}&print=true`} target="_blank">
<a className="follow__btn" href={`${apiUrl}/public/previews/challenges?challenge=${encodeURIComponent(challenge.uuid)}&print=true`} target="_blank" rel="noopener noreferrer">
<span className="details__btn">
<svg className="usa-icon" aria-hidden="true" focusable="false" role="img"
style={{fill: "#FA9441", height: "21px", width: "21px", position: "relative", top: "5px", right: "5px"}}>
Expand Down
6 changes: 3 additions & 3 deletions assets/client/src/components/ChallengeTile.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ export const ChallengeTile = ({challenge, preview}) => {
<div className="agency_image_wrapper">
<img
className="agency-logo"
src={imageBase + challenge.agency_logo}
src={`${imageBase}${encodeURIComponent(challenge.agency_logo)}`}
alt={truncateString(`Agency Logo: ${challenge.agency_name}`, 90)}
/>
</div>
Expand All @@ -134,7 +134,7 @@ export const ChallengeTile = ({challenge, preview}) => {
<div className="image_wrapper">
<img
className="agency-logo"
src={imageBase + challenge.agency_logo}
src={`${imageBase}${encodeURIComponent(challenge.agency_logo)}`}
alt={truncateString(`Agency Logo: ${challenge.agency_name}`, 90)}
/>
</div>
Expand All @@ -144,7 +144,7 @@ export const ChallengeTile = ({challenge, preview}) => {
return (
challenge ? (
<div key={challenge.id} className="challenge-tile card">
<a href={challengeTileUrl(challenge, preview)} target={challenge.external_url ? "_blank" : ""} aria-label="">
<a href={encodeURI(challengeTileUrl(challenge, preview))} target={challenge.external_url ? "_blank" : ""} aria-label="">
{renderTileLogo()}
<div className="challenge-tile__text-wrapper">
<h2 className="challenge-tile__title test" aria-label="" style={{ textAlign: 'left', paddingLeft: '20px', paddingTop: '20px', lineHeight: '30px' }}>{truncateString(challenge.title, 90)}</h2>
Expand Down
6 changes: 3 additions & 3 deletions assets/client/src/components/PreviewBanner.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ export const PreviewBanner = ({challenge}) => {
<div>
<span className="me-3">Preview generated on {formatDateToLLLL()}</span>
<a className="me-3" href={window.location.href}>Refresh page</a>
{!challenge.external_url &&
<a href={apiUrl + `/public/previews/challenges?challenge=${challenge.uuid}&print=true`} target="_blank">Print</a>
}
{!challenge.external_url && (
<a href={`${apiUrl}/public/previews/challenges?challenge=${encodeURIComponent(challenge.uuid)}&print=true`} target="_blank">Print</a>
)}
</div>
<br/>
<div>Link to share for internal agency review:</div>
Expand Down
4 changes: 2 additions & 2 deletions assets/client/src/components/challenge_tabs/Winners.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export const Winners = ({challenge, challengePhases, print}) => {
if (phaseWinner.overview_image_path) {
return (
<img
src={imageBase + phaseWinner.overview_image_path}
src={`${imageBase}${encodeURIComponent(phaseWinner.overview_image_path)}`}
alt="Phase Winner image"
title="Phase Winner image"
className="phase-winner-image mt-3"
Expand All @@ -23,7 +23,7 @@ export const Winners = ({challenge, challengePhases, print}) => {
const {id, image_path, name, place_title} = winner
return (
<div key={id} className="d-flex flex-row align-items-center usa-tbm-1rem">
{image_path && <img src={imageBase + winner.image_path} alt="winner image" title="winner image" className="phase-winner-image me-3" />}
{image_path && (<img src={`${imageBase}${encodeURIComponent(winner.image_path)}`} alt="winner image" title="winner image" className="phase-winner-image me-3" />)}
{name && <p>{name}</p>}
{place_title && <p>{` - ${place_title}`}</p>}
</div>
Expand Down
4 changes: 2 additions & 2 deletions assets/client/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ const renderRouter = () => (
)

const rootElement = document.getElementById('challenge-gov-react-app')
const apiUrl = rootElement.getAttribute('data-api-url')
const apiUrl = encodeURI(rootElement.getAttribute('data-api-url'))
const publicUrl = rootElement.getAttribute('data-public-url')
const imageBase = rootElement.getAttribute('data-image-base')
const imageBase = encodeURI(rootElement.getAttribute('data-image-base'))
const bridgeApplyBlocked = rootElement.getAttribute('data-bridge-apply-blocked') != 'false'

ReactDOM.render(renderRouter(), rootElement);
Expand Down
2 changes: 1 addition & 1 deletion assets/client/src/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const renderPreview = () => (
)

const rootElement = document.getElementById('preview');
const imageBase = rootElement.getAttribute('data-image-base');
const imageBase = encodeURI(rootElement.getAttribute('data-image-base'));
ReactDOM.render(renderPreview(), rootElement);

// If you want your app to work offline and load faster, you can change
Expand Down
4 changes: 2 additions & 2 deletions assets/js/app/_custom_url_generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ function set_custom_url_example() {
if (custom_url_example_text.length > 0) {
if (custom_url_input_value != "") {
challenge_title_slug = title_to_url_slug(custom_url_input_value)
custom_url_example_text.html(challenge_title_slug)
custom_url_example_text.text(challenge_title_slug)
} else {
challenge_title_slug = title_to_url_slug(challenge_title_input_value)
custom_url_example_text.html(challenge_title_slug)
custom_url_example_text.text(challenge_title_slug)
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions assets/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"create-react-app": "^5.0.1",
"file-loader": "^6.2.0",
"inputmask": "^5.0.5",
"jquery": "^3.3.1",
"jquery": "^3.7.1",
"moment": "^2.27.0",
"moment-timezone": "^0.5.31",
"node-quill-converter": "^0.3.3",
Expand Down Expand Up @@ -59,4 +59,4 @@
"webpack": "^5.76.0",
"webpack-cli": "^4.7.0"
}
}
}
Loading