mirror of
https://github.com/datahub-project/datahub.git
synced 2025-12-13 02:57:03 +00:00
fixes edge case issue: when a user clicks the fieldName without a source would not render the input box. increases the width for dropdown filter in search-bar component
This commit is contained in:
parent
74cbbf0263
commit
d9df311f40
@ -74,11 +74,10 @@ export default Component.extend({
|
|||||||
// Returns a list of owners with truthy value for their confirmedBy attribute,
|
// Returns a list of owners with truthy value for their confirmedBy attribute,
|
||||||
// i.e. they confirmedBy contains a userName and
|
// i.e. they confirmedBy contains a userName and
|
||||||
// type is `Owner` and idType is `USER`.
|
// type is `Owner` and idType is `USER`.
|
||||||
confirmedOwners: computed('owners.[]', function () {
|
confirmedOwners: computed('owners.[]', function() {
|
||||||
return getWithDefault(this, 'owners', []).filter(
|
return getWithDefault(this, 'owners', []).filter(
|
||||||
({ confirmedBy, type, idType }) => confirmedBy &&
|
({ confirmedBy, type, idType }) =>
|
||||||
type === 'Owner' &&
|
confirmedBy && type === 'Owner' && idType === 'USER'
|
||||||
idType === 'USER'
|
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
|
|
||||||
@ -98,10 +97,10 @@ export default Component.extend({
|
|||||||
* @type {Ember.ComputedProperty}
|
* @type {Ember.ComputedProperty}
|
||||||
* @requires _defaultOwnerUserName
|
* @requires _defaultOwnerUserName
|
||||||
*/
|
*/
|
||||||
userNameInvalid: computed('owners.[]', function () {
|
userNameInvalid: computed('owners.[]', function() {
|
||||||
return getWithDefault(this, 'owners', [])
|
return getWithDefault(this, 'owners', []).filter(
|
||||||
.filter(({ userName }) => userName === _defaultOwnerUserName)
|
({ userName }) => userName === _defaultOwnerUserName
|
||||||
.length > 0;
|
).length > 0;
|
||||||
}),
|
}),
|
||||||
|
|
||||||
didInsertElement() {
|
didInsertElement() {
|
||||||
@ -190,10 +189,12 @@ export default Component.extend({
|
|||||||
* wrapping TD element, which handles the bubbled Mouse click on the
|
* wrapping TD element, which handles the bubbled Mouse click on the
|
||||||
* label
|
* label
|
||||||
*/
|
*/
|
||||||
willEditUserName({ source = "" }, { currentTarget: { classList } }) {
|
willEditUserName({ source = '' }, { currentTarget: { classList } }) {
|
||||||
// Add the className cached in `userNameEditableClass`. This renders
|
// Add the className cached in `userNameEditableClass`. This renders
|
||||||
// the input element in the DOM, and removes the label from layout
|
// the input element in the DOM, and removes the label from layout
|
||||||
if (!source.includes("SCM") && typeof classList.add === 'function') {
|
if (
|
||||||
|
source && !source.includes('SCM') && typeof classList.add === 'function'
|
||||||
|
) {
|
||||||
classList.add(userNameEditableClass);
|
classList.add(userNameEditableClass);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@ -12,7 +12,7 @@ $height: 40px;
|
|||||||
* Rules for the search bar filter component
|
* Rules for the search bar filter component
|
||||||
*/
|
*/
|
||||||
&__filter {
|
&__filter {
|
||||||
width: 65px;
|
width: 75px;
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user