Skip to content

Commit

Permalink
Work for #5551 - Implement TOC navigation - changed app markup and li…
Browse files Browse the repository at this point in the history
…st selection behavior
  • Loading branch information
tsv2013 committed Jan 23, 2023
1 parent 22f171f commit 098d0a3
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 14 deletions.
28 changes: 15 additions & 13 deletions src/knockout/templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,24 @@
<!-- ko template: { name: 'survey-timerpanel' } -->
<!-- /ko -->
<!-- /ko -->
<!-- ko if: isShowProgressBarOnTop && !isShowStartingPage -->
<!-- ko component: { name: 'sv-progress-' + progressBarType, params: { model: $data } } -->
<!-- /ko -->
<!-- /ko -->
<div data-bind="css: bodyCss, style:{maxWidth: renderedWidth}, attr: { id: activePage ? activePage.id : '' }">
<div data-bind="css: bodyContainerCss">
<!-- ko if: isShowProgressBarOnTop && !isShowStartingPage -->
<!-- ko component: { name: 'sv-progress-' + progressBarType, params: { model: $data } } -->
<!-- /ko -->
<!-- /ko -->
<!-- ko if: isNavigationButtonsShowingOnTop -->
<!-- ko component: { name: 'sv-action-bar', params: { model: navigationBar } } --><!-- /ko -->
<!-- /ko -->
<!-- ko if: activePage -->
<!-- ko template: { name: 'survey-page', data: activePage, afterRender: koAfterRenderPage } -->
<!-- /ko -->
<!-- ko if: activePage.rows.length == 0 && $data.emptyPageTemplate -->
<!-- ko template: { name: emptyPageTemplate, data: $data.emptyPageTemplateData || $data } -->
<!-- /ko -->
<!-- /ko -->
<!-- /ko -->
<div data-bind="css: bodyCss, style:{maxWidth: renderedWidth}, attr: { id: activePage ? activePage.id : '' }">
<!-- ko if: activePage -->
<!-- ko template: { name: 'survey-page', data: activePage, afterRender: koAfterRenderPage } -->
<!-- /ko -->
<!-- ko if: activePage.rows.length == 0 && $data.emptyPageTemplate -->
<!-- ko template: { name: emptyPageTemplate, data: $data.emptyPageTemplateData || $data } -->
<!-- /ko -->
<!-- /ko -->
<!-- /ko -->
</div>
<!-- ko if: isShowProgressBarOnBottom && !isShowStartingPage -->
<!-- ko component: { name: 'sv-progress-' + progressBarType, params: { model: $data } } -->
<!-- /ko -->
Expand Down
2 changes: 1 addition & 1 deletion src/list.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ export class ListModel extends ActionContainer {
};

public isItemSelected: (itemValue: Action) => boolean = (itemValue: Action) => {
return !!this.allowSelection && !!this.selectedItem && this.selectedItem.id == itemValue.id;
return !!this.selectedItem && this.selectedItem.id == itemValue.id;
};

public isItemFocused: (itemValue: Action) => boolean = (itemValue: Action) => {
Expand Down

0 comments on commit 098d0a3

Please sign in to comment.