Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
10 changes: 5 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ repos:
# biome-format Format the committed files
# biome-lint Lint and apply safe fixes to the committed files
- repo: https://github.com/biomejs/pre-commit
rev: v2.5.2
rev: v2.5.8
hooks:
- id: biome-check
additional_dependencies: ["@biomejs/biome@^1.9.4"]
Expand All @@ -58,7 +58,7 @@ repos:

# runs the ruff linter and formatter
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.15.20
rev: v0.16.3
hooks:
# linter
- id: ruff-check # runs ruff check --force-exclude
Expand Down Expand Up @@ -95,22 +95,22 @@ repos:

# linter for django templates
- repo: https://github.com/Riverside-Healthcare/djLint
rev: v1.40.4
rev: v1.44.2
hooks:
- id: djlint-reformat-django
- id: djlint-django

# linter for markdown files - see .rumdl.toml to configure rules
- repo: https://github.com/rvben/rumdl-pre-commit
rev: v0.2.27
rev: v0.2.55
hooks:
- id: rumdl # Lint only (fails on issues)
- id: rumdl-fmt # Auto-format and fail if issues remain
stages: [pre-commit]

# runs pyrefly type checker on the sdk project
- repo: https://github.com/facebook/pyrefly-pre-commit
rev: 1.2.0.dev1
rev: 1.3.0.dev1
hooks:
- id: pyrefly-check
name: pyrefly-check (sdk)
Expand Down
2 changes: 1 addition & 1 deletion gateway/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@
format_js = true
# TODO: remove T002 when fixed https://github.com/djlint/djLint/issues/687
# https://www.djlint.com/docs/configuration/#ignore
ignore = "H006,H030,H031,T002"
ignore = "H006,H030,H031,T002,T038"
include = "H017,H035"
indent = 4
max_line_length = 119
Expand Down
12 changes: 6 additions & 6 deletions gateway/sds_gateway/templates/account/login.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
{% if not SOCIALACCOUNT_ONLY %}
{% setvar link %}
<a href="{{ signup_url }}">
{% endsetvar %}
{% setvar end_link %}
</a>
{% endsetvar %}
{% element p %}
{% blocktranslate %}New here? {{ link }}Create an account{{ end_link }}.{% endblocktranslate %}
{% endsetvar %}
{% setvar end_link %}
</a>
{% endsetvar %}
{% element p %}
{% blocktranslate %}New here? {{ link }}Create an account{{ end_link }}.{% endblocktranslate %}
{% endelement %}
{% url 'account_login' as login_url %}
{% element form form=form method="post" action=login_url tags="entrance,login" %}
Expand Down
3 changes: 1 addition & 2 deletions gateway/sds_gateway/templates/admin/base_site.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
<h1 id="site-name">
<a href="{% url 'admin:index' %}">Django Administration · <span class="mono">{{ ADMIN_CONSOLE_ENV }}</span> · <span class="mono">{{ SDS_SITE_FQDN }}</span></a>
{% if ADMIN_MONITORING_STATUS %}
<span class="admin-monitoring-pill admin-monitoring-pill--{{ ADMIN_MONITORING_STATUS.overall_status }}"
title="{% for child in ADMIN_MONITORING_STATUS.child_statuses %}{{ child.service_name }}: {{ child.status }}{% if not forloop.last %} | {% endif %}{% endfor %}">
<span class="admin-monitoring-pill admin-monitoring-pill--{{ ADMIN_MONITORING_STATUS.overall_status }}" title="{% for child in ADMIN_MONITORING_STATUS.child_statuses %}{{ child.service_name }}: {{ child.status }}{% if not forloop.last %} | {% endif %}{% endfor %}">
overall: {{ ADMIN_MONITORING_STATUS.overall_status }}
</span>
{% endif %}
Expand Down
24 changes: 12 additions & 12 deletions gateway/sds_gateway/templates/allauth/elements/field.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,18 @@
<div class="col-sm-10">
<label for="{{ attrs.id }}">
{% slot label %}
{% endslot %}
</label>
</div>
<textarea {% if attrs.required %}required{% endif %}
{% if attrs.rows %}rows="{{ attrs.rows }}"{% endif %}
{% if attrs.disabled %}disabled{% endif %}
{% if attrs.readonly %}readonly{% endif %}
{% if attrs.checked %}checked{% endif %}
{% if attrs.name %}name="{{ attrs.name }}"{% endif %}
{% if attrs.id %}id="{{ attrs.id }}"{% endif %}
{% if attrs.placeholder %}placeholder="{{ attrs.placeholder }}"{% endif %}
class="form-control">{% slot value %}{% endslot %}</textarea>
{% endslot %}
</label>
</div>
<textarea {% if attrs.required %}required{% endif %}
{% if attrs.rows %}rows="{{ attrs.rows }}"{% endif %}
{% if attrs.disabled %}disabled{% endif %}
{% if attrs.readonly %}readonly{% endif %}
{% if attrs.checked %}checked{% endif %}
{% if attrs.name %}name="{{ attrs.name }}"{% endif %}
{% if attrs.id %}id="{{ attrs.id }}"{% endif %}
{% if attrs.placeholder %}placeholder="{{ attrs.placeholder }}"{% endif %}
class="form-control">{% slot value %}{% endslot %}</textarea>
</div>
{% elif attrs.type == "radio" %}
<div class="row mb-3">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,43 +14,42 @@

{# Wrapper for ListRefreshManager; omitted when injecting into existing wrapper #}
{% if not ajax_fragment %}<div id="dataset-list-ajax-wrapper">{% endif %}
<!-- Results count display -->
{% if page_obj.object_list %}
<div class="d-flex justify-content-end mb-3">
<span id="results-count" aria-live="polite" class="text-muted">
{{ page_obj.paginator.count }} {{ asset_type|default:"asset" }}{{ page_obj.paginator.count|pluralize }} found
</span>
</div>
{% endif %}
<!-- AJAX‑Updatable Table & Pagination -->
<div id="dynamic-table-container" class="table-and-pagination">
<div class="table-container">
<div class="table-responsive">
{% if not page_obj.object_list %}
<table class="table table-striped table-hover datasets-table-fixed {{ table_class|default:'' }}">
<caption class="visually-hidden">Your {{ asset_type|default:"asset" }} list</caption>
{% include "users/components/asset_list_table_thead.html" %}
</table>
<div class="alert alert-info" role="alert">
<h4 class="alert-heading">No {{ asset_type|default:"asset" }}s yet</h4>
<p>{{ no_assets_message }}</p>
</div>
{% else %}
<table class="table table-striped table-hover datasets-table-fixed {{ table_class|default:'' }}">
<caption class="visually-hidden">Your {{ asset_type|default:"asset" }} list</caption>
{% include "users/components/asset_list_table_thead.html" %}
<tbody>
{% for asset in page_obj %}
{% if "dataset_list_table_row" in asset_row_template %}
{% include asset_row_template with dataset=asset dropdown_menu_items=asset.dropdown_menu_items %}
{% else %}
{% include asset_row_template with capture=asset dropdown_menu_items=asset.dropdown_menu_items %}
{% endif %}
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
<!-- Results count display -->
{% if page_obj.object_list %}
<div class="d-flex justify-content-end mb-3">
<span id="results-count" aria-live="polite" class="text-muted">
{{ page_obj.paginator.count }} {{ asset_type|default:"asset" }}{{ page_obj.paginator.count|pluralize }} found
</span>
</div>
{% endif %}
<!-- AJAX‑Updatable Table & Pagination -->
<div id="dynamic-table-container" class="table-and-pagination">
<div class="table-container">
<div class="table-responsive">
{% if not page_obj.object_list %}
<table class="table table-striped table-hover datasets-table-fixed {{ table_class|default:'' }}">
<caption class="visually-hidden">Your {{ asset_type|default:"asset" }} list</caption>
{% include "users/components/asset_list_table_thead.html" %}
</table>
<div class="alert alert-info" role="alert">
<h4 class="alert-heading">No {{ asset_type|default:"asset" }}s yet</h4>
<p>{{ no_assets_message }}</p>
</div>
{% else %}
<table class="table table-striped table-hover datasets-table-fixed {{ table_class|default:'' }}">
<caption class="visually-hidden">Your {{ asset_type|default:"asset" }} list</caption>
{% include "users/components/asset_list_table_thead.html" %}
<tbody>
{% for asset in page_obj %}
{% if "dataset_list_table_row" in asset_row_template %}
{% include asset_row_template with dataset=asset dropdown_menu_items=asset.dropdown_menu_items %}
{% else %}
{% include asset_row_template with capture=asset dropdown_menu_items=asset.dropdown_menu_items %}
{% endif %}
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
</div>
{% if page_obj and page_obj.has_other_pages %}
Expand Down Expand Up @@ -101,6 +100,7 @@ <h4 class="alert-heading">No {{ asset_type|default:"asset" }}s yet</h4>
</ul>
</nav>
{% endif %}
{% if not ajax_fragment %}
</div>
{% if not ajax_fragment %}
</div>
{% endif %}
Original file line number Diff line number Diff line change
Expand Up @@ -43,16 +43,16 @@
<td class="capture-col-created text-nowrap" headers="created-header">
{% if capture.capture.created_at %}
{% localtime on %}
<div class="d-flex align-items-center gap-2">
<span class="bg-transparent pe-2">{{ capture.capture.created_at|date:"Y-m-d" }}</span>
<span class="text-muted bg-transparent">{{ capture.capture.created_at|date:"H:i:s T" }}</span>
</div>
{% endlocaltime %}
{% else %}
-
{% endif %}
</td>
<td class="capture-col-actions text-center" headers="actions-header">
{% include "users/components/dropdown_menu.html" with items=dropdown_menu_items %}
</td>
<div class="d-flex align-items-center gap-2">
<span class="bg-transparent pe-2">{{ capture.capture.created_at|date:"Y-m-d" }}</span>
<span class="text-muted bg-transparent">{{ capture.capture.created_at|date:"H:i:s T" }}</span>
</div>
{% endlocaltime %}
{% else %}
-
{% endif %}
</td>
<td class="capture-col-actions text-center" headers="actions-header">
{% include "users/components/dropdown_menu.html" with items=dropdown_menu_items %}
</td>
</tr>
Original file line number Diff line number Diff line change
Expand Up @@ -73,92 +73,92 @@ <h6 class="mb-0">
<p class="mb-0 dataset-details-updated">
{% if dataset_updated_at %}
{% localtime on %}
{{ dataset_updated_at|date:"M j, Y, g:i A" }}
{% endlocaltime %}
{% else %}
{% endif %}
</p>
{{ dataset_updated_at|date:"M j, Y, g:i A" }}
{% endlocaltime %}
{% else %}
{% endif %}
</p>
</div>
</div>
</div>
</div>
<div class="mb-3">
<label class="fw-bold text-muted">Description:</label>
<p class="mb-0 dataset-details-description">{{ dataset.description|default:"No description provided" }}</p>
</div>
<div class="mb-3">
<label class="fw-bold text-muted">Keywords:</label>
<div class="dataset-details-keywords">
{% if dataset.keywords %}
{% for keyword in dataset.keywords %}<span class="badge bg-secondary me-2 mb-2">{{ keyword }}</span>{% endfor %}
{% else %}
<span class="text-muted">No keywords</span>
{% endif %}
<div class="mb-3">
<label class="fw-bold text-muted">Description:</label>
<p class="mb-0 dataset-details-description">{{ dataset.description|default:"No description provided" }}</p>
</div>
<div class="mb-3">
<label class="fw-bold text-muted">Keywords:</label>
<div class="dataset-details-keywords">
{% if dataset.keywords %}
{% for keyword in dataset.keywords %}<span class="badge bg-secondary me-2 mb-2">{{ keyword }}</span>{% endfor %}
{% else %}
<span class="text-muted">No keywords</span>
{% endif %}
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="card">
<div class="card-header bg-light">
<h6 class="mb-0">
<i class="bi bi-files me-2"></i>File Summary
</h6>
</div>
<div class="card-body">
<div class="row">
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Total Files</h6>
<p class="mb-0 fw-bold text-primary" id="total-files-count">{{ statistics.total_files }}</p>
<div class="row">
<div class="col-12">
<div class="card">
<div class="card-header bg-light">
<h6 class="mb-0">
<i class="bi bi-files me-2"></i>File Summary
</h6>
</div>
<div class="card-body">
<div class="row">
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Total Files</h6>
<p class="mb-0 fw-bold text-primary" id="total-files-count">{{ statistics.total_files }}</p>
</div>
</div>
</div>
</div>
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Capture Files</h6>
<p class="mb-0 fw-bold text-success" id="captures-count">{{ statistics.captures }}</p>
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Capture Files</h6>
<p class="mb-0 fw-bold text-success" id="captures-count">{{ statistics.captures }}</p>
</div>
</div>
</div>
</div>
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Artifact Files</h6>
<p class="mb-0 fw-bold text-info" id="artifacts-count">{{ statistics.artifacts }}</p>
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Artifact Files</h6>
<p class="mb-0 fw-bold text-info" id="artifacts-count">{{ statistics.artifacts }}</p>
</div>
</div>
</div>
</div>
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Total Size</h6>
<p class="mb-0 fw-bold text-warning" id="total-size">{{ statistics.total_size|filesizeformat }}</p>
<div class="col-md-3">
<div class="card bg-light">
<div class="card-body text-center">
<h6 class="card-title mb-1">Total Size</h6>
<p class="mb-0 fw-bold text-warning" id="total-size">{{ statistics.total_size|filesizeformat }}</p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<hr class="my-3" />
<div class="d-flex align-items-center text-muted small">
<i class="bi bi-code-slash me-2"></i>
<span>
<a href="https://sds.crc.nd.edu/sdk/api/datasets/"
target="_blank"
rel="noopener"
class="text-decoration-none">SDK Datasets API</a>
· <a href="https://sds.crc.nd.edu/sdk/common-workflows/dataset-downloads/"
<hr class="my-3" />
<div class="d-flex align-items-center text-muted small">
<i class="bi bi-code-slash me-2"></i>
<span>
<a href="https://sds.crc.nd.edu/sdk/api/datasets/"
target="_blank"
rel="noopener"
class="text-decoration-none">SDK Datasets API</a>
· <a href="https://sds.crc.nd.edu/sdk/common-workflows/dataset-downloads/"
target="_blank"
rel="noopener"
class="text-decoration-none">Download via SDK</a>
</span>
</div>
</span>
</div>
</div>
Loading
Loading