mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-24 01:29:35 +02:00
* Remove bootstrap-3 entrypoint * Rename bootstrap-5 entrypoint to bootstrap * Restore entrypoints * Remove `bootstrap-5` and `bootstrap-3` entrypoints and a single `bootstrap.ts` file is now the default entrypoint * Update `bootstrap-5` component imports to `bootstrap` * Update `bootstrap-5` CSS imports to `bootstrap` * Remove the `isBootstrap5` utility * Remove `bootstrapVersion` * Remove `ol-bootstrapVersion` * Remove getCssThemeModifier * Update path and rename * Source format * Remove Bootstrap v3 and Bootstrap v5 alias npm packages * Remove bootstrap argument * Remove unused files * Update with the latest split tests * Remove remaining bootstrap5PageStatus * Update path GitOrigin-RevId: 7acda2f80114d2de8699e1f06729a2a29218e284
18 lines
389 B
JavaScript
18 lines
389 B
JavaScript
export function disableElement(el) {
|
|
if (el.tagName.toLowerCase() === 'a') {
|
|
el.classList.add('disabled')
|
|
} else {
|
|
el.disabled = true
|
|
}
|
|
el.setAttribute('aria-disabled', 'true')
|
|
}
|
|
|
|
export function enableElement(el) {
|
|
if (el.tagName.toLowerCase() === 'a') {
|
|
el.classList.remove('disabled')
|
|
} else {
|
|
el.disabled = false
|
|
}
|
|
el.removeAttribute('aria-disabled')
|
|
}
|