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
2 changes: 1 addition & 1 deletion .github/workflows/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v10.4.0
- uses: actions/stale@v11.0.0
with:
stale-issue-label: "stale"
stale-pr-label: "stale"
Expand Down
5 changes: 5 additions & 0 deletions Web/css/librebooking.css
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,11 @@ fieldset:disabled .btn {
border-color: var(--primary-disabled);
}

a.disabled {
pointer-events: none;
opacity: 0.5;
}

.link-primary {
color: var(--primary) !important;
text-decoration: none;
Expand Down
14 changes: 13 additions & 1 deletion Web/scripts/calendar.js
Original file line number Diff line number Diff line change
Expand Up @@ -455,8 +455,20 @@ function Calendar(opts) {
var url = _options.getSubscriptionUrl + '&rid=' + rid + '&sid=' + sid + '&gid=' + gid;
ajaxGet(
url,
function () {},
function () {
// Disable the link while it may still reflect the previous filter selection.
// The href and inline onclick are dropped as well: pointer-events: none only
// blocks the mouse, so a focused link could otherwise still be activated with
// the keyboard and copy the stale subscription URL to the clipboard.
$('#subscribeToCalendar')
.addClass('disabled')
.attr('aria-disabled', 'true')
.removeAttr('onclick')
.removeAttr('href');
},
function (response) {
// Re-enabling happens by replacement: the link lives inside #calendarSubscription
// and is rendered fresh, enabled, and carrying the current filter's URL.
$('#calendarSubscription').html(response);
}
);
Expand Down