on 2019 Nov 13 6:17 AM
Hello Experts,
I'm using version 1.65 of SAPUI5.
In older versions when I wanted to set width of the app to 100% I set the appWidthLimited property of the Shell component to false.
sap.ui.getCore().attachInit(function() {
new sap.m.Shell({
appWidthLimited : false,
app: new sap.ui.core.ComponentContainer({
height : "100%",
name : "creditreport"
})
}).placeAt("content");
});
In the newer version Shell is no longer part of the index.html, there is only html which looks like this:
<body class="sapUiBody orlPersonalExpenses">
<div
data-sap-ui-component
data-name="com.company.personal.expenses.PersonalExpenses"
data-id="container"
data-settings='{"id" : "PersonalExpenses"}'>
</div>
</body>
I searched in the DOM and found the 'sapMShellCentralBox', then I used CSS in order to change it
<style>
.orlPersonalExpenses .sapMShellCentralBox {
width: 100% !important;
margin-right: 0px !important;
right: 0 !important;
}
</style>
Is there an API to set width to 100%? as we all know CSS hacks will eventually come back to bite you in the a*s (-:
Regards,
Omri
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
> In the newer version Shell is no longer part of the index.html
Look for other Shell occurances in your project. Maybe it moved to the root view?
Otherwise, see the following answer in How to disable letterboxing and adjust UI5 for the widescreen?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks.
Tried it:
"sap.ui": {
"technology": "UI5",
"icons": {
"icon": "",
"favIcon": "",
"phone": "",
"phone@2": "",
"tablet": "",
"tablet@2": ""
},
"deviceTypes": {
"desktop": true,
"tablet": true,
"phone": true
},
"fullWidth": true
},
didn't work. What am I missing?
Regards,
Omri
User | Count |
---|---|
68 | |
8 | |
8 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.