Sfoglia il codice sorgente

Remove unused Javascript

Jeremy Stretch 2 anni fa
parent
commit
f41105d5e3

File diff suppressed because it is too large
+ 0 - 0
netbox/project-static/dist/netbox.js


File diff suppressed because it is too large
+ 0 - 0
netbox/project-static/dist/netbox.js.map


+ 0 - 15
netbox/project-static/src/links.ts

@@ -1,15 +0,0 @@
-import { isTruthy, getElements } from './util';
-
-/**
- * Allow any element to be made "clickable" with the use of the `data-href` attribute.
- */
-export function initLinks(): void {
-  for (const link of getElements('*[data-href]')) {
-    const href = link.getAttribute('data-href');
-    if (isTruthy(href)) {
-      link.addEventListener('click', () => {
-        window.location.assign(href);
-      });
-    }
-  }
-}

+ 0 - 2
netbox/project-static/src/netbox.ts

@@ -12,7 +12,6 @@ import { initInterfaceTable } from './tables';
 import { initSideNav } from './sidenav';
 import { initDashboard } from './dashboard';
 import { initRackElevation } from './racks';
-import { initLinks } from './links';
 import { initHtmx } from './htmx';
 
 function initDocument(): void {
@@ -31,7 +30,6 @@ function initDocument(): void {
     initSideNav,
     initDashboard,
     initRackElevation,
-    initLinks,
     initHtmx,
   ]) {
     init();

Some files were not shown because too many files changed in this diff