Skip to content

Commit

Permalink
Merged in bugfix/SHIBUI-2115-cosmetic-errors (pull request #588)
Browse files Browse the repository at this point in the history
Fixed cosmetic issues

Approved-by: Dmitriy Kopylenko
Approved-by: Bill Smith
Former-commit-id: 870e1daf70936784f8d77b48122f3790d9479733
  • Loading branch information
rmathis committed Aug 8, 2022
2 parents 0649df2 + d929fc3 commit eabe9dc
Show file tree
Hide file tree
Showing 8 changed files with 31 additions and 15 deletions.
1 change: 1 addition & 0 deletions backend/src/main/resources/i18n/messages.properties
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,7 @@ label.remove-roleless-entity-descriptors=Remove Roleless Entity Descriptors?
label.remove-empty-entities-descriptors=Remove Empty Entities Descriptors?

label.select-metadata-provider-type=Select Metadata Provider Type
label.select-metadata-filter-type=Select Metadata Filter Type
label.filter-list=Filter List
label.common-attributes=Common Attributes
label.reloading-attributes=Reloading Attributes
Expand Down
21 changes: 16 additions & 5 deletions ui/public/unsecured/error.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,31 @@
<meta charset="utf-8">
<title th:text="#{messages.brand.header.title}">Shibboleth Metadata Management</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/x-icon" href="favicon.ico">
<link rel="icon" type="image/png" sizes="96x96" href="assets/favicon-96x96.png">
<link rel="icon" type="image/x-icon" href="/unsecured/favicon.ico">
<link rel="icon" type="image/png" sizes="96x96" href="/unsecured/favicon-96x96.png">
<link rel="stylesheet" type="text/css" href="/unsecured/static.css">
<base href="/">
</head>
<body>
<nav class="navbar navbar-expand-md fixed-top bg-white">
<span class="navbar-text" th:text="#{messages.brand.header.title}">Shibboleth Metadata Management</span>
<a href="https://www.shibboleth.net/" title="Shibboleth Logo" class="navbar-brand ms-4">
<img
src="/unsecured/shibboleth_icon_color_130x130.png" class="d-inline-block align-top" alt="brand.logo-alt" width="30"
height="30">
</a>
<span class=" navbar-text" th:text="#{messages.brand.header.title}">Shibboleth Metadata Management</span>
</nav>
<main class="container-fluid p-3">
<div class="d-flex justify-content-center">
<div class="card align-self-center">
<div class="card-body d-flex justify-content-between">
<i class="fa fa-fw fa-check-circle-o fa-3x text-success"></i>
<div class="card-body d-flex justify-content-between align-items-start">
<div class="w-50 text-success">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">
<path
d="M243.8 339.8C232.9 350.7 215.1 350.7 204.2 339.8L140.2 275.8C129.3 264.9 129.3 247.1 140.2 236.2C151.1 225.3 168.9 225.3 179.8 236.2L224 280.4L332.2 172.2C343.1 161.3 360.9 161.3 371.8 172.2C382.7 183.1 382.7 200.9 371.8 211.8L243.8 339.8zM512 256C512 397.4 397.4 512 256 512C114.6 512 0 397.4 0 256C0 114.6 114.6 0 256 0C397.4 0 512 114.6 512 256zM256 48C141.1 48 48 141.1 48 256C48 370.9 141.1 464 256 464C370.9 464 464 370.9 464 256C464 141.1 370.9 48 256 48z"
fill="#498500" />
</svg>
</div>
<div class="ml-2 px-3">
<h5 class="card-title" th:text="#{messages.message.user-request-received-title}">User request received</h5>
<p class="card-text" th:text="#{messages.message.user-request-received-body}">Your request has been received and is being reviewed. You will be notified with access status.</p>
Expand Down
Binary file added ui/public/unsecured/favicon-96x96.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ui/public/unsecured/favicon.ico
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions ui/src/app/metadata/new/NewProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { MetadataProviderTypeSelector } from '../wizard/MetadataProviderTypeSele

export function NewProvider() {

const { data = [] } = useMetadataProviderTypes({}, []);
const { data = [], loading } = useMetadataProviderTypes({}, []);

return (
<div className="container-fluid p-3">
Expand All @@ -20,7 +20,7 @@ export function NewProvider() {
</div>
</div>
<div className="section-body p-4 border border-top-0 border-info">
<MetadataProviderTypeSelector type={'provider'} types={[...data]}>
<MetadataProviderTypeSelector type={'provider'} types={[...data]} loading={loading}>
{(data, onRestart) =>
<MetadataSchema type={data.type} wizard={true}>
<MetadataWizard type="provider"
Expand Down
8 changes: 4 additions & 4 deletions ui/src/app/metadata/wizard/MetadataFilterTypeSelector.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,14 @@ export function MetadataFilterTypeSelector({ types = [], children, actions}) {
<Form onSubmit={handleSubmit()}>
<Form.Group className="mb-0">
<Form.Label>
<span><Translate value={'label.metadata-provider-type'} /></span>
<InfoIcon value="tooltip.metadata-provider-type" />
<span><Translate value={'label.metadata-filter-type'} /></span>
<InfoIcon value="tooltip.metadata-filter-type" />
</Form.Label>
<Form.Select
defaultValue={''}
placeholder={translator(`label.select-metadata-type`)}
placeholder={translator(`label.select-metadata-filter-type`)}
{...register('type', { required: true })}>
<option disabled value="">{translator(`label.select-metadata-type`)}</option>
<option disabled value="">{translator(`label.select-metadata-filter-type`)}</option>
{types.map(t => <option key={t} value={t}>{t}</option>)}
</Form.Select>
</Form.Group>
Expand Down
12 changes: 8 additions & 4 deletions ui/src/app/metadata/wizard/MetadataProviderTypeSelector.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { faArrowCircleRight, faSpinner } from '@fortawesome/free-solid-svg-icons';
import { faArrowCircleRight, faAsterisk, faSpinner } from '@fortawesome/free-solid-svg-icons';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';

import { useForm } from 'react-hook-form';
Expand All @@ -10,11 +10,11 @@ import { InfoIcon } from '../../form/component/InfoIcon';
import { useTranslator } from '../../i18n/hooks';
import { useMetadataProviders } from '../hooks/api';

export function MetadataProviderTypeSelector({ type, types = [], children}) {
export function MetadataProviderTypeSelector({ type, types = [], loading, children}) {

const translator = useTranslator();

const { data = [], loading } = useMetadataProviders({cachePolicy: 'no-cache'}, []);
const { data = [] } = useMetadataProviders({cachePolicy: 'no-cache'}, []);

const [showSelector, setShowSelector] = React.useState(true);

Expand Down Expand Up @@ -81,7 +81,10 @@ export function MetadataProviderTypeSelector({ type, types = [], children}) {
<Form onSubmit={handleSubmit(onNext)}>
<Form.Group className={`${errors.name ? 'text-danger' : ''} mb-3`}>
<Form.Label>
<span><Translate value={'label.metadata-provider-name-dashboard-display-only'} /></span>
<span>
<Translate value={'label.metadata-provider-name-dashboard-display-only'} />
<FontAwesomeIcon icon={faAsterisk} className="ms-2 text-danger" size="sm" />
</span>
<InfoIcon value="tooltip.metadata-provider-name" />
</Form.Label>
<Form.Control
Expand All @@ -98,6 +101,7 @@ export function MetadataProviderTypeSelector({ type, types = [], children}) {
<Form.Label>
<span>
<Translate value={'label.metadata-provider-type'} />
<FontAwesomeIcon icon={faAsterisk} className="ms-2 text-danger" size="sm" />
{loading && <FontAwesomeIcon icon={faSpinner} size="lg" spin={true} pulse={true} className="ms-2" /> }
</span>
<InfoIcon value="tooltip.metadata-provider-type" />
Expand Down

0 comments on commit eabe9dc

Please sign in to comment.