Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(ui5-popover): improve layouting, styling and positioning #779

Merged
merged 11 commits into from
Oct 1, 2019
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/main/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@
"@wdio/sync": "^5.12.1",
"@webcomponents/webcomponentsjs": "^2.2.7",
"chai": "^4.2.0",
"chromedriver": "^76.0.0",
"chromedriver": "^77.0.0",
"clean-css": "^4.2.1",
"copy-and-watch": "^0.1.2",
"cpx": "^1.5.0",
Expand Down Expand Up @@ -153,6 +153,6 @@
"resolutions": {
"abstract-syntax-tree": "1.0.3",
"dir-glob": "2.0.0",
"wdio-chromedriver-service/chromedriver": "^76.0.0"
"wdio-chromedriver-service/chromedriver": "^77.0.0"
}
}
40 changes: 25 additions & 15 deletions packages/main/src/Popover.hbs
Original file line number Diff line number Diff line change
@@ -1,17 +1,27 @@
{{>include "./Popup.hbs"}}
<div class="ui5-popover-root" role="dialog" aria-modal="true" aria-labelledby="ui5-popover-header">

<span class="ui5-popup-frame" @focusin="{{onfocusin}}">
<span id="{{_id}}-firstfe" tabindex="0" @focusin={{focusHelper.forwardToLast}}></span>
<div style="{{styles.main}}" role="dialog" aria-modal="true" aria-labelledby="{{headerId}}" tabindex="-1" class="ui5-popup-root ui5-popover-root">
{{> header}}
<div id="{{_id}}-content" style="{{styles.content}}" class="ui5-popup-content">
<div class="ui5-popup-scroll">
<slot></slot>
</div>
</div>
{{> footer}}
<span id="{{_id}}-arrow" style="{{styles.arrow}}" class="ui5-popover-arr"></span>
<span class="ui5-popover-arr" style="{{styles.arrow}}"></span>

{{#if header.length }}
<div class="ui5-popover-header-root" id="ui5-popover-header" role="toolbar">
<slot name="header"></slot>
</div>
<span id="{{_id}}-lastfe" tabindex="0" @focusin={{focusHelper.forwardToFirst}}></span>
<div tabindex="0" id="{{_id}}-blocklayer" style="{{styles.blockLayer}}" class="{{classes.blockLayer}}"></div>
</span>
{{else}}
<h2 class="ui5-popup-header-text" id="ui5-popover-header">{{headerText}}</h2>
{{/if}}

<span class="first-fe" tabindex="0" @focusin={{forwardToLast}}></span>

<div class="ui5-popover-content">
<slot></slot>
</div>

<span class="last-fe" tabindex="0" @focusin={{forwardToFirst}}></span>

{{#if footer.length }}
<div class="ui5-popover-footer-root" role="toolbar">
<slot name="footer"></slot>
</div>
{{/if}}

</div>
Loading