Rename confusing "isSet" to "active page indicator"

We would love to name this state "selected", but that term is already
used for a template parameter that is checked/used. The idea of "set"
was to have a list of parameters where one is "set". But the word is
confusing. I suggest "active page" because the entire purpose of the
blue selection is to highlight the currently active page (i.e. the
one you currently interact with on the right side of the dialog) in
the sidebar.

Change-Id: I5a16ab4c193ea05c21bb3bf89ada2ef550d8d6bc
This commit is contained in:
Thiemo Kreuz 2022-07-18 16:36:37 +02:00 committed by Awight
parent 336a27e05b
commit 4782987a7f
3 changed files with 7 additions and 7 deletions

View file

@ -148,9 +148,9 @@
color: @on-click-text-color;
}
&.ve-ui-mwTransclusionOutlineParameterWidget-isSet,
&.ve-ui-mwTransclusionOutlineParameterWidget-isSet:hover,
&.ve-ui-mwTransclusionOutlineParameterWidget-isSet.oo-ui-optionWidget-highlighted {
&.ve-ui-mwTransclusionOutlineParameterWidget-activePage,
&.ve-ui-mwTransclusionOutlineParameterWidget-activePage:hover,
&.ve-ui-mwTransclusionOutlineParameterWidget-activePage.oo-ui-optionWidget-highlighted {
background-color: @selected-background;
color: @selected-text-color;
}

View file

@ -123,10 +123,10 @@ ve.ui.MWTransclusionOutlineParameterSelectWidget.prototype.setParameter = functi
this.itemSet = paramName;
if ( currentItem ) {
currentItem.setParameter( false );
currentItem.toggleActivePageIndicator( false );
}
if ( newItem ) {
newItem.setParameter( true );
newItem.toggleActivePageIndicator( true );
}
};

View file

@ -76,8 +76,8 @@ ve.ui.MWTransclusionOutlineParameterWidget.prototype.setSelected = function ( st
/**
* @param {boolean} state
*/
ve.ui.MWTransclusionOutlineParameterWidget.prototype.setParameter = function ( state ) {
this.$element.toggleClass( 've-ui-mwTransclusionOutlineParameterWidget-isSet', state );
ve.ui.MWTransclusionOutlineParameterWidget.prototype.toggleActivePageIndicator = function ( state ) {
this.$element.toggleClass( 've-ui-mwTransclusionOutlineParameterWidget-activePage', state );
};
/**