-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
26f30b6
commit 275ce20
Showing
11 changed files
with
125 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v6.12.1 | ||
v6.13.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
export default class HTMLUtilities | ||
{ | ||
static load_images(container) | ||
{ | ||
const images = container.querySelectorAll('img'); | ||
|
||
for (let i = 0; i < images.length; i++) | ||
{ | ||
const image = images[i]; | ||
|
||
if (image.dataset.src) | ||
{ | ||
image.src = image.dataset.src; | ||
} | ||
} | ||
|
||
const image_objects = container.querySelectorAll('object'); | ||
|
||
for (let i = 0; i < image_objects.length; i++) | ||
{ | ||
const image_object = image_objects[i]; | ||
|
||
if (image_object.dataset.src) | ||
{ | ||
image_object.data = image_object.dataset.src; | ||
} | ||
} | ||
} | ||
|
||
static load_videos(container) | ||
{ | ||
const videos = container.querySelectorAll('video'); | ||
|
||
for (let i = 0; i < videos.length; i++) | ||
{ | ||
const video = videos[i]; | ||
|
||
if (video.dataset.src) | ||
{ | ||
video.src = video.dataset.src; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
export class HTMLUtilities { | ||
/** | ||
* Load Images defined in data-src. | ||
*/ | ||
static load_images(container: HTMLElement): void; | ||
/** | ||
* Load Videos defined in data-src. | ||
*/ | ||
static load_videos(container: HTMLElement): void; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,16 @@ | ||
export class ObjectUtilities { | ||
static xml_to_json(xml: any): { | ||
'@attributes': {}; | ||
}; | ||
/** | ||
* Simple object check. | ||
*/ | ||
static is_object(item: any): boolean; | ||
|
||
/** | ||
* Deep merge two objects. | ||
*/ | ||
static merge_deep(target: any, ...sources: any): void; | ||
|
||
/** | ||
* Convert XML to JSON | ||
*/ | ||
static xml_to_json(xml: any): object; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters