mirror of https://github.com/apache/nifi.git
[NIFI-2898] restore ellipsis for processor type, controller servies type, and reporting task type descriptions. This closes #1191
This commit is contained in:
parent
57e6a2d515
commit
52cde9ad13
|
@ -25,10 +25,8 @@
|
|||
</div>
|
||||
<div class="setting">
|
||||
<div class="setting-name">Description</div>
|
||||
<div class="setting-field">
|
||||
<div id="component-state-description" class="ellipsis multiline"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div id="component-state-partial-results-container" class="hidden">
|
||||
Showing partial results
|
||||
|
|
|
@ -52,7 +52,10 @@
|
|||
|
||||
#component-state-description{
|
||||
height: 75px;
|
||||
overflow: auto;
|
||||
line-height: normal;
|
||||
color: #775351;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -45,22 +45,23 @@
|
|||
}
|
||||
|
||||
#controller-service-type-name {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 2px;
|
||||
min-height: 15px;
|
||||
padding: 0px 0px 5px 0px;
|
||||
color: #775351;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
#controller-service-type-name-title {
|
||||
font-family: Roboto Slab;
|
||||
padding: 20px 0px 10px 0px;
|
||||
padding: 20px 0 5px 0;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#controller-service-type-description {
|
||||
height: 62px;
|
||||
font-size: 12px;
|
||||
line-height: 16px;
|
||||
font-size: 13px;
|
||||
line-height: 17px;
|
||||
padding-top: 10px;
|
||||
}
|
||||
|
||||
#controller-service-types-table {
|
||||
|
|
|
@ -45,23 +45,23 @@
|
|||
}
|
||||
|
||||
#processor-type-name {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 2px;
|
||||
min-height: 15px;
|
||||
padding: 0px 0px 5px 0px;
|
||||
color: #775351;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
#processor-type-name-title {
|
||||
font-family: Roboto Slab;
|
||||
padding: 20px 0px 10px 0px;
|
||||
padding: 20px 0 5px 0;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#processor-type-description {
|
||||
height: 62px;
|
||||
font-size: 12px;
|
||||
line-height: 16px;
|
||||
overflow-y: auto;
|
||||
font-size: 13px;
|
||||
line-height: 17px;
|
||||
padding-top: 10px;
|
||||
}
|
||||
|
||||
#processor-types-table {
|
||||
|
|
|
@ -45,22 +45,23 @@
|
|||
}
|
||||
|
||||
#reporting-task-type-name {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 2px;
|
||||
min-height: 15px;
|
||||
padding: 0px 0px 5px 0px;
|
||||
color: #775351;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
#reporting-task-type-name-title {
|
||||
font-family: Roboto Slab;
|
||||
padding: 20px 0px 10px 0px;
|
||||
padding: 20px 0 5px 0;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#reporting-task-type-description {
|
||||
height: 62px;
|
||||
font-size: 12px;
|
||||
line-height: 16px;
|
||||
font-size: 13px;
|
||||
line-height: 17px;
|
||||
padding-top: 10px;
|
||||
}
|
||||
|
||||
#reporting-task-types-table {
|
||||
|
|
|
@ -46,6 +46,7 @@
|
|||
*
|
||||
* overflow: hidden;
|
||||
* white-space: nowrap;
|
||||
* width: 50px (value must be set in 'px')
|
||||
*
|
||||
* If multiline is desired, add a 'multiline' class to the element.
|
||||
*
|
||||
|
|
|
@ -305,13 +305,16 @@ nf.ng.ProcessorComponent = function (serviceProvider) {
|
|||
// set the processor type description
|
||||
if (nf.Common.isDefinedAndNotNull(processorType)) {
|
||||
if (nf.Common.isBlank(processorType.description)) {
|
||||
$('#processor-type-description').attr('title', '').html('<span class="unset">No description specified</span>');
|
||||
$('#processor-type-description')
|
||||
.attr('title', '')
|
||||
.html('<span class="unset">No description specified</span>');
|
||||
} else {
|
||||
$('#processor-type-description').html(processorType.description).ellipsis();
|
||||
$('#processor-type-description')
|
||||
.width($('#processor-description-container').innerWidth() - 1)
|
||||
.html(processorType.description)
|
||||
.ellipsis();
|
||||
}
|
||||
|
||||
nf.Common.toggleScrollable($('#processor-type-description').get(0));
|
||||
|
||||
// populate the dom
|
||||
$('#processor-type-name').text(processorType.label).ellipsis();
|
||||
$('#selected-processor-name').text(processorType.label);
|
||||
|
@ -404,7 +407,15 @@ nf.ng.ProcessorComponent = function (serviceProvider) {
|
|||
// configure the new processor dialog
|
||||
this.getElement().modal({
|
||||
scrollableContentStyle: 'scrollable',
|
||||
headerText: 'Add Processor'
|
||||
headerText: 'Add Processor',
|
||||
handler: {
|
||||
resize: function () {
|
||||
$('#processor-type-description')
|
||||
.width($('#processor-description-container').innerWidth() - 1)
|
||||
.text($('#processor-type-description').attr('title'))
|
||||
.ellipsis();
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
|
|
|
@ -222,6 +222,12 @@ nf.ComponentState = (function () {
|
|||
handler: {
|
||||
close: function () {
|
||||
resetDialog();
|
||||
},
|
||||
resize: function () {
|
||||
$('#component-state-description')
|
||||
.width($('#component-state-dialog').find('.dialog-content').innerWidth() - 1)
|
||||
.text($('#component-state-description').attr('title'))
|
||||
.ellipsis();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -351,16 +357,19 @@ nf.ComponentState = (function () {
|
|||
// load the table
|
||||
loadComponentState(componentState.localState, componentState.clusterState);
|
||||
|
||||
// show the dialog
|
||||
$('#component-state-dialog').modal('show');
|
||||
|
||||
// populate the name/description
|
||||
$('#component-state-name').text(componentEntity.component.name);
|
||||
$('#component-state-description').text(componentState.stateDescription).ellipsis();
|
||||
$('#component-state-description')
|
||||
.width($('#component-state-dialog').find('.dialog-content').innerWidth() - 1)
|
||||
.text(componentState.stateDescription)
|
||||
.ellipsis();
|
||||
|
||||
// store the component
|
||||
componentStateTable.data('component', componentEntity);
|
||||
|
||||
// show the dialog
|
||||
$('#component-state-dialog').modal('show');
|
||||
|
||||
// only activate the link when appropriate
|
||||
if (canClear === false) {
|
||||
$('#clear-link').addClass('disabled').attr('title', 'Component state can only be cleared when the component is not actively running');
|
||||
|
|
|
@ -280,19 +280,24 @@ nf.ControllerServices = (function () {
|
|||
|
||||
// set the controller service type description
|
||||
if (nf.Common.isDefinedAndNotNull(controllerServiceType)) {
|
||||
// show the selected controller service
|
||||
$('#controller-service-description-container').show();
|
||||
|
||||
if (nf.Common.isBlank(controllerServiceType.description)) {
|
||||
$('#controller-service-type-description').attr('title', '').html('<span class="unset">No description specified</span>');
|
||||
$('#controller-service-type-description')
|
||||
.attr('title', '')
|
||||
.html('<span class="unset">No description specified</span>');
|
||||
} else {
|
||||
$('#controller-service-type-description').html(controllerServiceType.description).ellipsis();
|
||||
$('#controller-service-type-description')
|
||||
.width($('#controller-service-description-container').innerWidth() - 1)
|
||||
.html(controllerServiceType.description)
|
||||
.ellipsis();
|
||||
}
|
||||
|
||||
// populate the dom
|
||||
$('#controller-service-type-name').text(controllerServiceType.label).ellipsis();
|
||||
$('#selected-controller-service-name').text(controllerServiceType.label);
|
||||
$('#selected-controller-service-type').text(controllerServiceType.type);
|
||||
|
||||
// show the selected controller service
|
||||
$('#controller-service-description-container').show();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -379,6 +384,12 @@ nf.ControllerServices = (function () {
|
|||
var controllerServiceTypesGrid = $('#controller-service-types-table').data('gridInstance');
|
||||
controllerServiceTypesGrid.setSelectedRows([]);
|
||||
controllerServiceTypesGrid.resetActiveCell();
|
||||
},
|
||||
resize: function () {
|
||||
$('#controller-service-type-description')
|
||||
.width($('#controller-service-description-container').innerWidth() - 1)
|
||||
.text($('#controller-service-type-description').attr('title'))
|
||||
.ellipsis();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -440,19 +440,24 @@ nf.Settings = (function () {
|
|||
|
||||
// set the reporting task type description
|
||||
if (nf.Common.isDefinedAndNotNull(reportingTaskType)) {
|
||||
// show the selected reporting task
|
||||
$('#reporting-task-description-container').show();
|
||||
|
||||
if (nf.Common.isBlank(reportingTaskType.description)) {
|
||||
$('#reporting-task-type-description').attr('title', '').html('<span class="unset">No description specified</span>');
|
||||
$('#reporting-task-type-description')
|
||||
.attr('title', '')
|
||||
.html('<span class="unset">No description specified</span>');
|
||||
} else {
|
||||
$('#reporting-task-type-description').html(reportingTaskType.description).ellipsis();
|
||||
$('#reporting-task-type-description')
|
||||
.width($('#reporting-task-description-container').innerWidth() - 1)
|
||||
.html(reportingTaskType.description)
|
||||
.ellipsis();
|
||||
}
|
||||
|
||||
// populate the dom
|
||||
$('#reporting-task-type-name').text(reportingTaskType.label).ellipsis();
|
||||
$('#selected-reporting-task-name').text(reportingTaskType.label);
|
||||
$('#selected-reporting-task-type').text(reportingTaskType.type);
|
||||
|
||||
// show the selected reporting task
|
||||
$('#reporting-task-description-container').show();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -569,6 +574,12 @@ nf.Settings = (function () {
|
|||
var reportingTaskTypesGrid = $('#reporting-task-types-table').data('gridInstance');
|
||||
reportingTaskTypesGrid.setSelectedRows([]);
|
||||
reportingTaskTypesGrid.resetActiveCell();
|
||||
},
|
||||
resize: function () {
|
||||
$('#reporting-task-type-description')
|
||||
.width($('#reporting-task-description-container').innerWidth() - 1)
|
||||
.text($('#reporting-task-type-description').attr('title'))
|
||||
.ellipsis();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue