mirror of
https://github.com/ente-io/ente.git
synced 2025-08-08 15:30:40 +00:00
Use order to position it
This commit is contained in:
parent
c17d0d0087
commit
6653b36764
@ -304,11 +304,19 @@ export class FileViewerPhotoSwipe {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Add our custom UI elements to inside the PhotoSwipe dialog.
|
// Add our custom UI elements to inside the PhotoSwipe dialog.
|
||||||
|
//
|
||||||
|
// API docs for registerElement:
|
||||||
|
// https://photoswipe.com/adding-ui-elements/#uiregisterelement-api
|
||||||
|
//
|
||||||
|
// The "order" prop is used to position items. Some landmarks:
|
||||||
|
// - counter: 5
|
||||||
|
// - zoom: 10
|
||||||
|
// - close: 20
|
||||||
pswp.on("uiRegister", () => {
|
pswp.on("uiRegister", () => {
|
||||||
pswp.ui.registerElement({
|
pswp.ui.registerElement({
|
||||||
name: "info-button",
|
name: "info-button",
|
||||||
ariaLabel: "File info",
|
ariaLabel: "File info",
|
||||||
// order:
|
order: 15,
|
||||||
isButton: true,
|
isButton: true,
|
||||||
html: "Info",
|
html: "Info",
|
||||||
onClick: (e) => {
|
onClick: (e) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user