-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- added dependency on packages `68publishers/oauth` and `thenetworg/oauth2-azure` - added yarn dependency on `clipboard` - added database migration - added new entity `ExternalAuth` in the User domain - added `AzureAuthSettings` into the Global settings - added azure settings form on the application settings page - added possibility to sign in via Azure - added copy buttons support for text form fields - added translations
- Loading branch information
Showing
68 changed files
with
1,695 additions
and
16 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
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,62 @@ | ||
const Clipboard = require('clipboard'); | ||
const tippy = require('tippy.js').default; | ||
|
||
(function () { | ||
(ready => { | ||
if (document.readyState !== 'loading') { | ||
ready(); | ||
return; | ||
} | ||
|
||
document.addEventListener('DOMContentLoaded', ready); | ||
})(() => { | ||
const timeouts = new WeakMap(); | ||
|
||
const showTooltip = (trigger, text) => { | ||
if (!trigger._tippy) { | ||
tippy(trigger, { | ||
content: '', | ||
placement: 'bottom', | ||
trigger: 'manual', | ||
}) | ||
} | ||
|
||
tooltip = trigger._tippy; | ||
tooltip.setContent(text); | ||
tooltip.show(); | ||
|
||
if (timeouts.has(trigger)) { | ||
clearTimeout(timeouts.get(trigger)); | ||
} | ||
|
||
const timeout = setTimeout(() => { | ||
tooltip.hide(); | ||
clearTimeout(timeouts.get(trigger)); | ||
}, 1500); | ||
|
||
timeouts.set(trigger, timeout); | ||
}; | ||
|
||
const cp = new Clipboard('[data-clipboard]'); | ||
|
||
cp.on('success', function (e) { | ||
e.clearSelection(); | ||
|
||
const tooltipText = e.trigger.dataset.clipboardSuccessTooltip || undefined; | ||
|
||
if (tooltipText) { | ||
showTooltip(e.trigger, tooltipText); | ||
} | ||
}); | ||
|
||
cp.on('error', function (e) { | ||
e.clearSelection(); | ||
|
||
const tooltipText = e.trigger.dataset.clipboardErrorTooltip || undefined; | ||
|
||
if (tooltipText) { | ||
showTooltip(e.trigger, tooltipText); | ||
} | ||
}); | ||
}); | ||
})(); |
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
Oops, something went wrong.