mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-30 20:14:49 +00:00
Fix/UI misc (#1606)
* stop expansion when description icon clicked * add test for ensuring string sanitization * rename log out to terminate in sessions component and remove sanitization bypass as unneeded * remove unecessary instances of safe string
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
*ngIf="data.spec.description"
|
||||
class="slot-start"
|
||||
fill="clear"
|
||||
(click)="presentAlertDescription()"
|
||||
(click)="presentAlertDescription($event)"
|
||||
>
|
||||
<ion-icon name="help-circle-outline" slot="icon-only" size="small"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
size="small"
|
||||
(click)="
|
||||
presentUnionTagDescription(
|
||||
$event,
|
||||
unionSpec.tag.name,
|
||||
unionSpec.tag.description
|
||||
)
|
||||
@@ -121,7 +122,7 @@
|
||||
<ion-button
|
||||
*ngIf="spec.description"
|
||||
fill="clear"
|
||||
(click)="presentAlertDescription(spec)"
|
||||
(click)="presentAlertDescription($event, spec)"
|
||||
style="--padding-start: 0"
|
||||
>
|
||||
<ion-icon
|
||||
|
||||
@@ -300,7 +300,8 @@ export class FormObjectComponent {
|
||||
await alert.present()
|
||||
}
|
||||
|
||||
async presentAlertDescription(spec: ValueSpec) {
|
||||
async presentAlertDescription(event: Event, spec: ValueSpec) {
|
||||
event.stopPropagation()
|
||||
const { name, description } = spec
|
||||
|
||||
const alert = await this.alertCtrl.create({
|
||||
@@ -353,7 +354,12 @@ export class FormObjectComponent {
|
||||
return `${key}-${index}-${this.objectId}`
|
||||
}
|
||||
|
||||
async presentUnionTagDescription(name: string, description: string) {
|
||||
async presentUnionTagDescription(
|
||||
event: Event,
|
||||
name: string,
|
||||
description: string,
|
||||
) {
|
||||
event.stopPropagation()
|
||||
const alert = await this.alertCtrl.create({
|
||||
header: name,
|
||||
message: description,
|
||||
@@ -384,7 +390,8 @@ export class FormLabelComponent {
|
||||
|
||||
constructor(private readonly alertCtrl: AlertController) {}
|
||||
|
||||
async presentAlertDescription() {
|
||||
async presentAlertDescription(event: Event) {
|
||||
event.stopPropagation()
|
||||
const { name, description } = this.data.spec
|
||||
|
||||
const alert = await this.alertCtrl.create({
|
||||
|
||||
Reference in New Issue
Block a user