Skip to content
Projects
Groups
Snippets
Help
Sign in / Register
Toggle navigation
Minds Frontend
Project overview
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
399
Merge Requests
51
CI / CD
Security & Compliance
Packages
Wiki
Snippets
Members
Collapse sidebar
Close sidebar
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Minds
Minds Frontend
Commits
b5bdb373
Commit
b5bdb373
authored
3 hours ago
by
Mark Harding
Browse files
Options
Download
(fix): firefox not able to focus on inputs - closes
#2288
parent
a46d28f5
master
No related merge requests found
Pipeline
#99930642
waiting for manual action with stages
in 47 minutes and 36 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
35 additions
and
0 deletions
+35
-0
src/app/common/components/draggable-list/list.component.html
View file @
b5bdb373
...
...
@@ -25,6 +25,7 @@
[dndDraggable]=
"item"
[dndEffectAllowed]=
"'move'"
[dndDragImageOffsetFunction]=
"dragImageOffsetRight"
[dndDisableIf]=
"disabled"
class=
"m-draggableList__listItem"
>
<ng-container
...
...
This diff is collapsed.
src/app/common/components/draggable-list/list.component.ts
View file @
b5bdb373
...
...
@@ -22,6 +22,7 @@ export class DraggableListComponent {
@
Input
()
dndEffectAllowed
:
EffectAllowed
=
'
copyMove
'
;
@
Input
()
id
:
string
;
@
Input
()
headers
:
string
[];
@
Input
()
disabled
:
boolean
;
@
ContentChild
(
TemplateRef
,
{
static
:
false
})
template
:
TemplateRef
<
any
>
;
@
Output
()
emptyListHeaderRowClicked
:
EventEmitter
<
any
>
=
new
EventEmitter
();
@
Output
()
arrayChanged
:
EventEmitter
<
any
>
=
new
EventEmitter
();
...
...
@@ -77,4 +78,19 @@ export class DraggableListComponent {
y
:
event
.
offsetY
+
10
,
};
};
/**
* If input is focused then disable dragging
*/
onFocusIn
(
e
:
FocusEvent
|
MouseEvent
)
{
this
.
disabled
=
true
;
}
/**
* Re-enable when input not focused
* TODO: Make this smarter.. what if something else disabled the dragging?
*/
onFocusOut
(
e
:
FocusEvent
|
MouseEvent
)
{
this
.
disabled
=
false
;
}
}
This diff is collapsed.
src/app/modules/pro/settings/settings.component.html
View file @
b5bdb373
...
...
@@ -559,6 +559,7 @@
[id]=
"'tag'"
(emptyListHeaderRowClicked)=
"addBlankTag()"
(arrayChanged)=
"setTags($event)"
#hashtagDraggable
>
<ng-template
let-tag=
"item"
let-i=
"i"
>
<ng-container
[formGroupName]=
"i"
>
...
...
@@ -569,6 +570,10 @@
[name]=
"'tag[' + i + '][label]'"
formControlName=
"label"
autofocus
(focusin)=
"hashtagDraggable.onFocusIn($event)"
(focusout)=
"hashtagDraggable.onFocusOut($event)"
(mouseover)=
"hashtagDraggable.onFocusIn($event)"
(mouseout)=
"hashtagDraggable.onFocusOut($event)"
/>
<input
class=
"m-draggableList__cell form-control"
...
...
@@ -576,6 +581,10 @@
[id]=
"'tag-tag-' + i"
[name]=
"'tag[' + i + '][tag]'"
formControlName=
"tag"
(focusin)=
"hashtagDraggable.onFocusIn($event)"
(focusout)=
"hashtagDraggable.onFocusOut($event)"
(mouseover)=
"hashtagDraggable.onFocusIn($event)"
(mouseout)=
"hashtagDraggable.onFocusOut($event)"
/>
</ng-container>
</ng-template>
...
...
@@ -622,6 +631,7 @@
[id]=
"'title'"
(emptyListHeaderRowClicked)=
"addBlankFooterLink()"
(arrayChanged)=
"setFooterLinks($event)"
#footerDraggable
>
<ng-template
let-link=
"item"
let-i=
"i"
>
<ng-container
[formGroupName]=
"i"
>
...
...
@@ -632,6 +642,10 @@
[name]=
"'footer_link[' + i + '][title]'"
formControlName=
"title"
autofocus
(focusin)=
"footerDraggable.onFocusIn($event)"
(focusout)=
"footerDraggable.onFocusOut($event)"
(mouseover)=
"footerDraggable.onFocusIn($event)"
(mouseout)=
"footerDraggable.onFocusOut($event)"
/>
<input
...
...
@@ -640,6 +654,10 @@
[id]=
"'footer_link-href-' + i"
[name]=
"'footer_link[' + i + '][href]'"
formControlName=
"href"
(focusin)=
"footerDraggable.onFocusIn($event)"
(focusout)=
"footerDraggable.onFocusOut($event)"
(mouseover)=
"footerDraggable.onFocusIn($event)"
(mouseout)=
"footerDraggable.onFocusOut($event)"
/>
</ng-container>
</ng-template>
...
...
This diff is collapsed.
Please
register
or
sign in
to comment