-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #882 from auth0/feature/auth0-universal-login-cust…
…omize DXCDT-544: Add `universal-login customize` command
- Loading branch information
Showing
35 changed files
with
11,985 additions
and
8 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
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,43 @@ | ||
--- | ||
layout: default | ||
parent: auth0 universal-login | ||
has_toc: false | ||
--- | ||
# auth0 universal-login customize | ||
|
||
Customize and preview changes to the Universal Login experience. This command will open a webpage within your browser where you can edit and preview your branding changes. For a comprehensive list of editable parameters and their values please visit the [Management API Documentation](https://auth0.com/docs/api/management/v2). | ||
|
||
## Usage | ||
``` | ||
auth0 universal-login customize [flags] | ||
``` | ||
|
||
## Examples | ||
|
||
``` | ||
auth0 universal-login customize | ||
auth0 ul customize | ||
``` | ||
|
||
|
||
|
||
|
||
## Inherited Flags | ||
|
||
``` | ||
--debug Enable debug mode. | ||
--no-color Disable colors. | ||
--no-input Disable interactivity. | ||
--tenant string Specific tenant to use. | ||
``` | ||
|
||
|
||
## Related Commands | ||
|
||
- [auth0 universal-login customize](auth0_universal-login_customize.md) - Customize the Universal Login experience | ||
- [auth0 universal-login prompts](auth0_universal-login_prompts.md) - Manage custom text for prompts | ||
- [auth0 universal-login show](auth0_universal-login_show.md) - Display the custom branding settings for Universal Login | ||
- [auth0 universal-login templates](auth0_universal-login_templates.md) - Manage custom Universal Login templates | ||
- [auth0 universal-login update](auth0_universal-login_update.md) - Update the custom branding settings for Universal Login | ||
|
||
|
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
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,17 @@ | ||
//go:generate mockgen -source=branding_theme.go -destination=mock/branding_theme_mock.go -package=mock | ||
|
||
package auth0 | ||
|
||
import ( | ||
"context" | ||
|
||
"github.com/auth0/go-auth0/management" | ||
) | ||
|
||
type BrandingThemeAPI interface { | ||
Default(ctx context.Context, opts ...management.RequestOption) (theme *management.BrandingTheme, err error) | ||
Create(ctx context.Context, theme *management.BrandingTheme, opts ...management.RequestOption) (err error) | ||
Read(ctx context.Context, id string, opts ...management.RequestOption) (theme *management.BrandingTheme, err error) | ||
Update(ctx context.Context, id string, theme *management.BrandingTheme, opts ...management.RequestOption) (err error) | ||
Delete(ctx context.Context, id string, opts ...management.RequestOption) (err error) | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
46 changes: 46 additions & 0 deletions
46
internal/cli/data/branding/storybook/branding-customization-notification.js
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,46 @@ | ||
document.addEventListener('DOMContentLoaded', function () { | ||
var checkIfStorybookRendered = setInterval(function () { | ||
var targetDiv = document.querySelectorAll("#panel-tab-content > div")[0]; | ||
if (targetDiv) { | ||
clearInterval(checkIfStorybookRendered); | ||
var insertHTML = ` | ||
<div | ||
id="branding-customization-notification" | ||
style=" | ||
padding: 30px 20px 20px; | ||
background: #ffff57; | ||
margin: 0; | ||
position:relative; | ||
" | ||
> | ||
<p style=" | ||
line-height: 1.45em; | ||
font-size: 1.4em; | ||
">An improved branding customization UI experience is available through the <b><code>auth0 universal-login customize</code></b> command.</p> | ||
<button | ||
id="branding-close-button" | ||
style=" | ||
position: absolute; | ||
top:0px; | ||
right:0px; | ||
background: transparent; | ||
border: none; | ||
padding: 10px 15px; | ||
cursor:pointer; | ||
text-decoration: underline; | ||
" | ||
>Close</button> | ||
</div> | ||
`; | ||
targetDiv.innerHTML = insertHTML + targetDiv.innerHTML; | ||
|
||
var brandingCloseButton = document.getElementById('branding-close-button'); | ||
brandingCloseButton.addEventListener('click', function () { | ||
var brandingCustomizationNotification = document.getElementById('branding-customization-notification'); | ||
if (brandingCustomizationNotification) { | ||
brandingCustomizationNotification.remove(); | ||
} | ||
}); | ||
} | ||
}, 100); | ||
}); |
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
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+28.8 KB
internal/cli/data/universal-login/assets/Inter-SemiBold-230d9756.woff2
Binary file not shown.
Binary file added
BIN
+34.7 KB
internal/cli/data/universal-login/assets/Inter-SemiBold-e108d97d.woff
Binary file not shown.
Oops, something went wrong.