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

fix: update how asl and lsq filters are applied to submissions #66

Merged
merged 3 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
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
4 changes: 1 addition & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@
"lint-staged": {
"*.css": "stylelint --fix",
"*.{js,cjs,json,jsonc}": "biome check --write --no-errors-on-unmatched",
"*.md": [
"markdownlint-cli2 --fix"
]
"*.md": ["markdownlint-cli2 --fix"]
}
}
5 changes: 4 additions & 1 deletion src/_includes/partials/components/submission.njk
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@
"
data-filter-language="
{%- if submission.data.youtube.interpretation -%}
{{ 'asl' if submission.data.youtube.lang === 'en' else 'lsq' }},
{{ 'asl' if submission.data.youtube.lang === 'en' and submission.data.youtube.signLanguageUrl }},
{%- endif -%}
{%- if submission.data.youtube.interpretation -%}
{{ 'lsq' if submission.data.youtube.lang === 'fr' and submission.data.youtube.signLanguageUrl }},
{%- endif -%}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You probably can consolidate this a little bit as there are two if clauses that do the same thing (check if there's an interpretation).

{%- if submission.data.youtube.lang === 'en' or submission.data.text.en or submission.data.transcript.en or submission.data.slides.en or submission.data.audio.lang === 'en' or submission.data.pdf.en -%}
en,
Expand Down