@openui5/sap.ui.integration 1.111.2 → 1.112.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +6 -3
- package/src/sap/ui/integration/.library +10 -1
- package/src/sap/ui/integration/ActionDefinition.js +1 -1
- package/src/sap/ui/integration/Designtime.js +1 -1
- package/src/sap/ui/integration/Extension.js +5 -1
- package/src/sap/ui/integration/Host.js +5 -1
- package/src/sap/ui/integration/cards/AdaptiveContent.js +1 -1
- package/src/sap/ui/integration/cards/AnalyticalContent.js +1 -1
- package/src/sap/ui/integration/cards/AnalyticsCloudContent.js +1 -1
- package/src/sap/ui/integration/cards/BaseContent.js +12 -3
- package/src/sap/ui/integration/cards/BaseContentRenderer.js +12 -7
- package/src/sap/ui/integration/cards/BaseListContent.js +1 -1
- package/src/sap/ui/integration/cards/CalendarContent.js +11 -8
- package/src/sap/ui/integration/cards/ComponentContent.js +12 -2
- package/src/sap/ui/integration/cards/Footer.js +2 -2
- package/src/sap/ui/integration/cards/Header.js +1 -1
- package/src/sap/ui/integration/cards/ListContent.js +1 -1
- package/src/sap/ui/integration/cards/NumericHeader.js +1 -1
- package/src/sap/ui/integration/cards/ObjectContent.js +106 -101
- package/src/sap/ui/integration/cards/TableContent.js +1 -1
- package/src/sap/ui/integration/cards/TimelineContent.js +1 -1
- package/src/sap/ui/integration/cards/WebPageContent.js +1 -1
- package/src/sap/ui/integration/cards/actions/CardActions.js +15 -13
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputChoiceSet.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputDate.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputNumber.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputText.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputToggle.js +1 -1
- package/src/sap/ui/integration/cards/filters/BaseFilter.js +22 -13
- package/src/sap/ui/integration/cards/filters/DateRangeFilter.js +12 -6
- package/src/sap/ui/integration/cards/filters/FilterBar.js +1 -1
- package/src/sap/ui/integration/cards/filters/FilterBarFactory.js +1 -1
- package/src/sap/ui/integration/cards/filters/SearchFilter.js +1 -1
- package/src/sap/ui/integration/cards/filters/SelectFilter.js +1 -1
- package/src/sap/ui/integration/cards/list/MicrochartsResizeHelper.js +1 -1
- package/src/sap/ui/integration/controls/ActionsStrip.js +1 -1
- package/src/sap/ui/integration/controls/ActionsToolbar.js +1 -1
- package/src/sap/ui/integration/controls/LinkWithIcon.js +1 -1
- package/src/sap/ui/integration/controls/ListContentItem.js +1 -1
- package/src/sap/ui/integration/controls/Microchart.js +1 -1
- package/src/sap/ui/integration/controls/MicrochartLegend.js +1 -1
- package/src/sap/ui/integration/controls/ObjectStatus.js +1 -1
- package/src/sap/ui/integration/controls/Paginator.js +1 -1
- package/src/sap/ui/integration/customElements/CustomElementCardEditor.js +3 -0
- package/src/sap/ui/integration/customElements/CustomElementEditor.js +3 -0
- package/src/sap/ui/integration/designtime/baseEditor/BaseEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/PropertyEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/PropertyEditors.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/BasePropertyEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/PropertyEditorFactory.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/arrayEditor/ArrayEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/booleanEditor/BooleanEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/codeEditor/CodeEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/dateEditor/DateEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/dateTimeEditor/DateTimeEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/enumStringEditor/EnumStringEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/groupEditor/GroupEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/iconEditor/IconEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/iconEditor/IsInIconPool.validator.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/integerEditor/IntegerEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/jsonEditor/JsonEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/listEditor/ListEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/mapEditor/MapEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/multiSelectEditor/MultiSelectEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/numberEditor/NumberEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/objectArrayEditor/ObjectArrayEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/selectEditor/SelectEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/separatorEditor/SeparatorEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/stringEditor/StringEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/textAreaEditor/TextAreaEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/util/binding/ObjectBinding.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/util/unset.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsBoolean.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsDate.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsInteger.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsNumber.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsSelectedKey.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsStringList.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsUniqueKey.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsUniqueList.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsValidBinding.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/MaxLength.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/NotABinding.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/ValidatorRegistry.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/config/ObjectCardConfig.js +12 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n.properties +6 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ar.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_bg.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ca.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_cs.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_cy.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_da.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_de.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_el.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_GB.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_US_sappsd.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_US_saprigi.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_US_saptrc.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_es.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_es_MX.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_et.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_fi.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_fr.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_fr_CA.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_hi.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_hr.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_hu.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_id.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_it.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_iw.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ja.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_kk.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ko.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_lt.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_lv.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ms.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_nl.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_no.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_pl.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_pt.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_pt_PT.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ro.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ru.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sh.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sk.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sl.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sv.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_th.properties +5 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_tr.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_uk.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_vi.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_zh_CN.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_zh_TW.properties +4 -0
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/complexMapEditor/ComplexMapEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/destinationsEditor/DestinationsEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/filtersEditor/FiltersEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/iconEditor/IconEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/parametersEditor/ParametersEditor.js +1 -1
- package/src/sap/ui/integration/designtime/editor/Card.js +59 -0
- package/src/sap/ui/integration/designtime/editor/CardEditor.js +31 -20
- package/src/sap/ui/integration/designtime/editor/CardPreview.js +200 -64
- package/src/sap/ui/integration/designtime/editor/CardRenderer.js +65 -0
- package/src/sap/ui/integration/designtime/editor/css/CardPreview.css +82 -20
- package/src/sap/ui/integration/editor/Editor.js +93 -73
- package/src/sap/ui/integration/editor/EditorResourceBundles.js +94 -0
- package/src/sap/ui/integration/editor/Extension.js +1 -1
- package/src/sap/ui/integration/editor/Manifest.js +1 -1
- package/src/sap/ui/integration/editor/Settings.js +1 -1
- package/src/sap/ui/integration/editor/fields/BaseField.js +1 -1
- package/src/sap/ui/integration/editor/fields/BooleanField.js +1 -1
- package/src/sap/ui/integration/editor/fields/DateField.js +1 -1
- package/src/sap/ui/integration/editor/fields/DateTimeField.js +1 -1
- package/src/sap/ui/integration/editor/fields/DestinationField.js +1 -1
- package/src/sap/ui/integration/editor/fields/GroupField.js +1 -1
- package/src/sap/ui/integration/editor/fields/IntegerField.js +1 -1
- package/src/sap/ui/integration/editor/fields/NumberField.js +1 -1
- package/src/sap/ui/integration/editor/fields/ObjectField.js +9 -5
- package/src/sap/ui/integration/editor/fields/ObjectListField.js +1 -1
- package/src/sap/ui/integration/editor/fields/StringField.js +6 -3
- package/src/sap/ui/integration/editor/fields/StringListField.js +1 -1
- package/src/sap/ui/integration/editor/fields/fragment/Controller.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/ColorSelect.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/IconSelect.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/ShapeSelect.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/VizBase.js +1 -1
- package/src/sap/ui/integration/library-bootstrap.js +1 -1
- package/src/sap/ui/integration/library.js +31 -2
- package/src/sap/ui/integration/messagebundle.properties +9 -0
- package/src/sap/ui/integration/messagebundle_ar.properties +4 -2
- package/src/sap/ui/integration/messagebundle_bg.properties +4 -2
- package/src/sap/ui/integration/messagebundle_ca.properties +4 -2
- package/src/sap/ui/integration/messagebundle_cs.properties +4 -2
- package/src/sap/ui/integration/messagebundle_cy.properties +4 -2
- package/src/sap/ui/integration/messagebundle_da.properties +4 -2
- package/src/sap/ui/integration/messagebundle_de.properties +4 -2
- package/src/sap/ui/integration/messagebundle_el.properties +4 -2
- package/src/sap/ui/integration/messagebundle_en.properties +3 -1
- package/src/sap/ui/integration/messagebundle_en_GB.properties +3 -1
- package/src/sap/ui/integration/messagebundle_en_US_sappsd.properties +2 -0
- package/src/sap/ui/integration/messagebundle_en_US_saprigi.properties +3 -1
- package/src/sap/ui/integration/messagebundle_en_US_saptrc.properties +2 -0
- package/src/sap/ui/integration/messagebundle_es.properties +4 -2
- package/src/sap/ui/integration/messagebundle_es_MX.properties +4 -2
- package/src/sap/ui/integration/messagebundle_et.properties +4 -2
- package/src/sap/ui/integration/messagebundle_fi.properties +4 -2
- package/src/sap/ui/integration/messagebundle_fr.properties +4 -2
- package/src/sap/ui/integration/messagebundle_fr_CA.properties +4 -2
- package/src/sap/ui/integration/messagebundle_hi.properties +4 -2
- package/src/sap/ui/integration/messagebundle_hr.properties +4 -2
- package/src/sap/ui/integration/messagebundle_hu.properties +4 -2
- package/src/sap/ui/integration/messagebundle_id.properties +4 -2
- package/src/sap/ui/integration/messagebundle_it.properties +4 -2
- package/src/sap/ui/integration/messagebundle_iw.properties +4 -2
- package/src/sap/ui/integration/messagebundle_ja.properties +4 -2
- package/src/sap/ui/integration/messagebundle_kk.properties +4 -2
- package/src/sap/ui/integration/messagebundle_ko.properties +4 -2
- package/src/sap/ui/integration/messagebundle_lt.properties +4 -2
- package/src/sap/ui/integration/messagebundle_lv.properties +4 -2
- package/src/sap/ui/integration/messagebundle_ms.properties +4 -2
- package/src/sap/ui/integration/messagebundle_nl.properties +4 -2
- package/src/sap/ui/integration/messagebundle_no.properties +4 -2
- package/src/sap/ui/integration/messagebundle_pl.properties +4 -2
- package/src/sap/ui/integration/messagebundle_pt.properties +4 -2
- package/src/sap/ui/integration/messagebundle_pt_PT.properties +4 -2
- package/src/sap/ui/integration/messagebundle_ro.properties +4 -2
- package/src/sap/ui/integration/messagebundle_ru.properties +4 -2
- package/src/sap/ui/integration/messagebundle_sh.properties +4 -2
- package/src/sap/ui/integration/messagebundle_sk.properties +4 -2
- package/src/sap/ui/integration/messagebundle_sl.properties +4 -2
- package/src/sap/ui/integration/messagebundle_sv.properties +4 -2
- package/src/sap/ui/integration/messagebundle_th.properties +4 -2
- package/src/sap/ui/integration/messagebundle_tr.properties +4 -2
- package/src/sap/ui/integration/messagebundle_uk.properties +4 -2
- package/src/sap/ui/integration/messagebundle_vi.properties +4 -2
- package/src/sap/ui/integration/messagebundle_zh_CN.properties +4 -2
- package/src/sap/ui/integration/messagebundle_zh_TW.properties +4 -2
- package/src/sap/ui/integration/model/ContextModel.js +1 -1
- package/src/sap/ui/integration/model/ObservableModel.js +1 -1
- package/src/sap/ui/integration/model/PagingModelListBinding.js +1 -1
- package/src/sap/ui/integration/schemas/sap-card.json +51 -4
- package/src/sap/ui/integration/themes/base/ObjectContent.less +24 -0
- package/src/sap/ui/integration/util/BaseFactory.js +1 -1
- package/src/sap/ui/integration/util/BindingHelper.js +1 -1
- package/src/sap/ui/integration/util/BindingResolver.js +15 -8
- package/src/sap/ui/integration/util/CardObserver.js +1 -1
- package/src/sap/ui/integration/util/ContentFactory.js +1 -1
- package/src/sap/ui/integration/util/CsrfTokenHandler.js +1 -1
- package/src/sap/ui/integration/util/DataProvider.js +12 -12
- package/src/sap/ui/integration/util/DataProviderFactory.js +53 -20
- package/src/sap/ui/integration/util/Destinations.js +1 -1
- package/src/sap/ui/integration/util/ExtensionDataProvider.js +1 -1
- package/src/sap/ui/integration/util/Form.js +440 -0
- package/src/sap/ui/integration/util/HeaderFactory.js +1 -1
- package/src/sap/ui/integration/util/JSONBindingHelper.js +1 -1
- package/src/sap/ui/integration/util/LoadingProvider.js +1 -1
- package/src/sap/ui/integration/util/Manifest.js +1 -1
- package/src/sap/ui/integration/util/ManifestResolver.js +11 -4
- package/src/sap/ui/integration/util/Measurement.js +64 -33
- package/src/sap/ui/integration/util/RequestDataProvider.js +1 -1
- package/src/sap/ui/integration/util/ServiceDataProvider.js +1 -1
- package/src/sap/ui/integration/util/ServiceManager.js +1 -1
- package/src/sap/ui/integration/util/SkeletonCard.js +1 -1
- package/src/sap/ui/integration/util/Utils.js +1 -1
- package/src/sap/ui/integration/util/Validators.js +1 -1
- package/src/sap/ui/integration/widgets/Card.js +96 -50
- package/src/sap/ui/integration/widgets/CardRenderer.js +5 -0
- package/src/sap-ui-integration.js +1 -1
- package/ui5.yaml +8 -0
- package/src/sap/ui/integration/util/Forms.js +0 -204
|
@@ -10,7 +10,7 @@ sap.ui.define([
|
|
|
10
10
|
"sap/m/HBox",
|
|
11
11
|
"sap/m/Image",
|
|
12
12
|
"sap/m/ToggleButton",
|
|
13
|
-
"
|
|
13
|
+
"./Card",
|
|
14
14
|
"sap/ui/core/Core",
|
|
15
15
|
"sap/ui/dom/includeStylesheet",
|
|
16
16
|
"sap/ui/integration/util/CardMerger"
|
|
@@ -29,7 +29,7 @@ sap.ui.define([
|
|
|
29
29
|
* @alias sap.ui.integration.designtime.editor.CardPreview
|
|
30
30
|
* @author SAP SE
|
|
31
31
|
* @since 1.83.0
|
|
32
|
-
* @version 1.
|
|
32
|
+
* @version 1.112.2
|
|
33
33
|
* @private
|
|
34
34
|
* @experimental since 1.83.0
|
|
35
35
|
* @ui5-restricted
|
|
@@ -43,6 +43,12 @@ sap.ui.define([
|
|
|
43
43
|
},
|
|
44
44
|
card: {
|
|
45
45
|
type: "object"
|
|
46
|
+
},
|
|
47
|
+
parentWidth: {
|
|
48
|
+
type: "sap.ui.core.CSSSize"
|
|
49
|
+
},
|
|
50
|
+
parentHeight: {
|
|
51
|
+
type: "sap.ui.core.CSSSize"
|
|
46
52
|
}
|
|
47
53
|
},
|
|
48
54
|
aggregations: {
|
|
@@ -51,6 +57,13 @@ sap.ui.define([
|
|
|
51
57
|
multiple: false,
|
|
52
58
|
visibility: "hidden"
|
|
53
59
|
}
|
|
60
|
+
},
|
|
61
|
+
associations: {
|
|
62
|
+
_editor: {
|
|
63
|
+
type: "sap.ui.core.Control",
|
|
64
|
+
multiple: false,
|
|
65
|
+
visibility: "hidden"
|
|
66
|
+
}
|
|
54
67
|
}
|
|
55
68
|
},
|
|
56
69
|
renderer: {
|
|
@@ -67,22 +80,15 @@ sap.ui.define([
|
|
|
67
80
|
if (isDark()) {
|
|
68
81
|
oRm.class("sapUiIntegrationDTPreviewDark");
|
|
69
82
|
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
} else {
|
|
76
|
-
oRm.class("sapUiIntegrationDTPreviewMarginForAlignTopAndBottom");
|
|
77
|
-
}
|
|
83
|
+
var sPreviewPosition = oControl.getSettings().preview.position;
|
|
84
|
+
if (sPreviewPosition === "separate") {
|
|
85
|
+
oRm.class("sapUiIntegrationDTPreviewSeparate");
|
|
86
|
+
document.body.style.setProperty("--sapUiIntegrationEditorPreviewWidth", "100%");
|
|
87
|
+
document.body.style.setProperty("--sapUiIntegrationEditorPreviewHeight", "100%");
|
|
78
88
|
}
|
|
79
89
|
oRm.openEnd();
|
|
80
90
|
oRm.openStart("div", oControl.getId() + "-before");
|
|
81
91
|
oRm.attr("tabindex", "-1");
|
|
82
|
-
if (!oControl.getSettings().preview.interactive) {
|
|
83
|
-
oRm.class("before");
|
|
84
|
-
oRm.style("z-index", oControl.getParent()._iZIndex + 1);
|
|
85
|
-
}
|
|
86
92
|
oRm.openEnd();
|
|
87
93
|
oRm.close("div");
|
|
88
94
|
oRm.renderControl(oControl._getCardPreview());
|
|
@@ -95,6 +101,13 @@ sap.ui.define([
|
|
|
95
101
|
|| (oControl._getModes().indexOf("Mock") > -1 && oControl._getModes().indexOf("Abstract") > -1)) {
|
|
96
102
|
oRm.renderControl(oControl._getModeToggleButton());
|
|
97
103
|
}
|
|
104
|
+
if (oControl._getModes() !== "Abstract" && (!sPreviewPosition || sPreviewPosition === "right" || sPreviewPosition === "left")) {
|
|
105
|
+
oRm.renderControl(oControl._getResizeToggleButton());
|
|
106
|
+
}
|
|
107
|
+
if (sPreviewPosition === "top" || sPreviewPosition === "bottom") {
|
|
108
|
+
document.body.style.setProperty("--sapUiIntegrationEditorPreviewWidth", oControl.getParentWidth());
|
|
109
|
+
document.body.style.setProperty("--sapUiIntegrationEditorPreviewHeight", oControl.getParentHeight());
|
|
110
|
+
}
|
|
98
111
|
oRm.close("div");
|
|
99
112
|
}
|
|
100
113
|
}
|
|
@@ -137,6 +150,8 @@ sap.ui.define([
|
|
|
137
150
|
this._oCardPlaceholder.destroy();
|
|
138
151
|
}
|
|
139
152
|
Control.prototype.destroy.apply(this, arguments);
|
|
153
|
+
document.body.style.removeProperty("--sapUiIntegrationEditorPreviewWidth");
|
|
154
|
+
document.body.style.removeProperty("--sapUiIntegrationEditorPreviewHeight");
|
|
140
155
|
};
|
|
141
156
|
|
|
142
157
|
CardPreview.prototype.onAfterRendering = function () {
|
|
@@ -157,6 +172,11 @@ sap.ui.define([
|
|
|
157
172
|
}
|
|
158
173
|
};
|
|
159
174
|
|
|
175
|
+
CardPreview.prototype.getEditor = function () {
|
|
176
|
+
var sEditorId = this.getAssociation("_editor");
|
|
177
|
+
return Core.byId(sEditorId);
|
|
178
|
+
};
|
|
179
|
+
|
|
160
180
|
/**
|
|
161
181
|
* returns the a preview based on the current settings
|
|
162
182
|
*/
|
|
@@ -177,11 +197,13 @@ sap.ui.define([
|
|
|
177
197
|
oPreview.removeStyleClass("sapUiIntegrationDTPreviewScale");
|
|
178
198
|
oPreview.removeStyleClass("sapUiIntegrationDTPreviewScaleSpec");
|
|
179
199
|
var sLanguge = Core.getConfiguration().getLanguage().replaceAll('_', '-');
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
200
|
+
if (this._getCurrentSize() !== "Full") {
|
|
201
|
+
if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
202
|
+
// for the languages "ar-SA"(Arabic) and "he-IL"(Hebrew) which write from right to left, use spec style
|
|
203
|
+
oPreview.addStyleClass("sapUiIntegrationDTPreviewScaleSpec");
|
|
204
|
+
} else {
|
|
205
|
+
oPreview.addStyleClass("sapUiIntegrationDTPreviewScale");
|
|
206
|
+
}
|
|
185
207
|
}
|
|
186
208
|
} else {
|
|
187
209
|
oPreview.addStyleClass("sapUiIntegrationDTPreviewNoScale");
|
|
@@ -240,7 +262,7 @@ sap.ui.define([
|
|
|
240
262
|
};
|
|
241
263
|
}
|
|
242
264
|
}
|
|
243
|
-
var oCurrent = this.
|
|
265
|
+
var oCurrent = this.getEditor().getCurrentSettings();
|
|
244
266
|
placeholder = {
|
|
245
267
|
"sap.app": {
|
|
246
268
|
"type": "card",
|
|
@@ -268,8 +290,12 @@ sap.ui.define([
|
|
|
268
290
|
};
|
|
269
291
|
|
|
270
292
|
if (!this._oCardPlaceholder) {
|
|
271
|
-
this._oCardPlaceholder = new Card({
|
|
293
|
+
this._oCardPlaceholder = new Card({
|
|
294
|
+
dataMode: CardDataMode.Active,
|
|
295
|
+
readonly: true
|
|
296
|
+
});
|
|
272
297
|
this._oCardPlaceholder._setPreviewMode(true);
|
|
298
|
+
this._oCardPlaceholder.onfocusin = this._onfocusin.bind(this);
|
|
273
299
|
}
|
|
274
300
|
this._oCardPlaceholder.setManifest(placeholder);
|
|
275
301
|
this._oCardPlaceholder.refresh();
|
|
@@ -287,7 +313,7 @@ sap.ui.define([
|
|
|
287
313
|
transformOriginStyle: "0 0",
|
|
288
314
|
widthStyle: "400px + 10rem",
|
|
289
315
|
heightStyle: "700px - 1.5rem",
|
|
290
|
-
zIndex: this.
|
|
316
|
+
zIndex: this.getEditor()._iZIndex
|
|
291
317
|
};
|
|
292
318
|
};
|
|
293
319
|
|
|
@@ -296,14 +322,22 @@ sap.ui.define([
|
|
|
296
322
|
*/
|
|
297
323
|
CardPreview.prototype._getCardRealPreview = function () {
|
|
298
324
|
if (!this._oCardPreview) {
|
|
299
|
-
|
|
325
|
+
var bReadonly = !this.getSettings().preview.interactive;
|
|
326
|
+
this._oCardPreview = new Card({
|
|
327
|
+
dataMode: CardDataMode.Active,
|
|
328
|
+
readonly: bReadonly,
|
|
329
|
+
readonlyZIndex: this.getEditor()._iZIndex + 1
|
|
330
|
+
});
|
|
300
331
|
this._oCardPreview.setBaseUrl(this.getCard().getBaseUrl());
|
|
301
332
|
if (this._currentMode === "Mock") {
|
|
302
333
|
this._oCardPreview.setProperty("useMockData", true);
|
|
303
334
|
}
|
|
335
|
+
if (bReadonly) {
|
|
336
|
+
this._oCardPreview.onfocusin = this._onfocusin.bind(this);
|
|
337
|
+
}
|
|
304
338
|
}
|
|
305
339
|
this._initalChanges = this._initalChanges || this._oCardPreview.getManifestChanges() || [];
|
|
306
|
-
var aChanges = this._initalChanges.concat([this.
|
|
340
|
+
var aChanges = this._initalChanges.concat([this.getEditor().getCurrentSettings()]);
|
|
307
341
|
this._oCardPreview.setManifestChanges(aChanges);
|
|
308
342
|
this._oCardPreview.setManifest(this.getCard()._oCardManifest._oManifest.getRawJson());
|
|
309
343
|
this._oCardPreview.setHost(this.getCard().getHost());
|
|
@@ -322,7 +356,6 @@ sap.ui.define([
|
|
|
322
356
|
if (!this._oImagePlaceholder) {
|
|
323
357
|
var oHBox = new HBox();
|
|
324
358
|
oHBox.addStyleClass("sapFCard");
|
|
325
|
-
oHBox.setWidth("500px");
|
|
326
359
|
var baseUrl = this.getCard().getBaseUrl();
|
|
327
360
|
if (!baseUrl && typeof this.getCard().getManifest() === "string") {
|
|
328
361
|
baseUrl = this.getCard().getManifest();
|
|
@@ -331,8 +364,6 @@ sap.ui.define([
|
|
|
331
364
|
var src = baseUrl + "/" + mSettings.preview.src;
|
|
332
365
|
var oImg = new Image({ src: src });
|
|
333
366
|
oImg.addStyleClass("sapUiIntegrationDTPreviewImg");
|
|
334
|
-
oImg.setWidth("500px");
|
|
335
|
-
oImg.setHeight("600px");
|
|
336
367
|
oHBox.addItem(oImg);
|
|
337
368
|
this._oImagePlaceholder = oHBox;
|
|
338
369
|
}
|
|
@@ -340,6 +371,26 @@ sap.ui.define([
|
|
|
340
371
|
return this._oImagePlaceholder;
|
|
341
372
|
};
|
|
342
373
|
|
|
374
|
+
CardPreview.prototype._onfocusin = function (oEvent) {
|
|
375
|
+
if (this._oModeToggleButton) {
|
|
376
|
+
if (oEvent.srcControl !== this._oModeToggleButton && oEvent.relatedTarget !== this._oModeToggleButton.getDomRef() && oEvent.relatedTarget !== this.getDomRef("after")) {
|
|
377
|
+
this.getDomRef("after").focus();
|
|
378
|
+
} else {
|
|
379
|
+
this.getDomRef("before").focus();
|
|
380
|
+
}
|
|
381
|
+
} else if (this._oSizeToggleButton){
|
|
382
|
+
if (oEvent.srcControl !== this._oSizeToggleButton && oEvent.relatedTarget !== this._oSizeToggleButton.getDomRef() && oEvent.relatedTarget !== this.getDomRef("after")) {
|
|
383
|
+
this.getDomRef("after").focus();
|
|
384
|
+
} else {
|
|
385
|
+
this.getDomRef("before").focus();
|
|
386
|
+
}
|
|
387
|
+
} else if (oEvent.srcControl.isA("sap.f.cards.BaseHeader")) {
|
|
388
|
+
this.getDomRef("after").focus();
|
|
389
|
+
} else {
|
|
390
|
+
this.getDomRef("before").focus();
|
|
391
|
+
}
|
|
392
|
+
};
|
|
393
|
+
|
|
343
394
|
/**
|
|
344
395
|
* returns the available modes
|
|
345
396
|
*/
|
|
@@ -395,7 +446,7 @@ sap.ui.define([
|
|
|
395
446
|
* toggles the current mode from "Abstract" to "Live" or "Mock" and vice versa
|
|
396
447
|
* @returns {sap.m.ToggleButton}
|
|
397
448
|
*/
|
|
398
|
-
|
|
449
|
+
CardPreview.prototype._getModeToggleButton = function () {
|
|
399
450
|
var oBundle = Core.getLibraryResourceBundle("sap.ui.integration");
|
|
400
451
|
|
|
401
452
|
if (!this._oModeToggleButton) {
|
|
@@ -406,14 +457,32 @@ sap.ui.define([
|
|
|
406
457
|
this.update();
|
|
407
458
|
}.bind(this));
|
|
408
459
|
}
|
|
409
|
-
this._oModeToggleButton.removeStyleClass("
|
|
410
|
-
this._oModeToggleButton.removeStyleClass("
|
|
460
|
+
this._oModeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewModeButton");
|
|
461
|
+
this._oModeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewModeButtonSpec");
|
|
462
|
+
this._oModeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewModeButtonFull");
|
|
463
|
+
this._oModeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewModeButtonFullSpec");
|
|
464
|
+
this._oModeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewModeButtonVerticalFull");
|
|
465
|
+
this._oModeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewModeButtonVerticalFullSpec");
|
|
411
466
|
var sLanguge = Core.getConfiguration().getLanguage().replaceAll('_', '-');
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
467
|
+
if (this._getCurrentSize() === "Full") {
|
|
468
|
+
var sPreviewPosition = this.getSettings().preview.position;
|
|
469
|
+
if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
470
|
+
// for the languages "ar-SA"(Arabic) and "he-IL"(Hebrew) which write from right to left, use spec style
|
|
471
|
+
if (sPreviewPosition === "top" || sPreviewPosition === "bottom" || sPreviewPosition === "separate") {
|
|
472
|
+
this._oModeToggleButton.addStyleClass("sapUiIntegrationDTPreviewModeButtonVerticalFullSpec");
|
|
473
|
+
} else {
|
|
474
|
+
this._oModeToggleButton.addStyleClass("sapUiIntegrationDTPreviewModeButtonFullSpec");
|
|
475
|
+
}
|
|
476
|
+
} else if (sPreviewPosition === "top" || sPreviewPosition === "bottom" || sPreviewPosition === "separate") {
|
|
477
|
+
this._oModeToggleButton.addStyleClass("sapUiIntegrationDTPreviewModeButtonVerticalFull");
|
|
478
|
+
} else {
|
|
479
|
+
this._oModeToggleButton.addStyleClass("sapUiIntegrationDTPreviewModeButtonFull");
|
|
480
|
+
}
|
|
481
|
+
} else if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
482
|
+
// for the languages "ar-SA"(Arabic) and "he-IL"(Hebrew) which write from right to left, use spec style
|
|
483
|
+
this._oModeToggleButton.addStyleClass("sapUiIntegrationDTPreviewModeButtonSpec");
|
|
415
484
|
} else {
|
|
416
|
-
this._oModeToggleButton.addStyleClass("
|
|
485
|
+
this._oModeToggleButton.addStyleClass("sapUiIntegrationDTPreviewModeButton");
|
|
417
486
|
}
|
|
418
487
|
var tb = this._oModeToggleButton,
|
|
419
488
|
currentMode = this._getCurrentMode();
|
|
@@ -436,6 +505,103 @@ sap.ui.define([
|
|
|
436
505
|
return this._oModeToggleButton;
|
|
437
506
|
};
|
|
438
507
|
|
|
508
|
+
/**
|
|
509
|
+
* returns the current size of the preview, "Full" or "Normal"
|
|
510
|
+
*/
|
|
511
|
+
CardPreview.prototype._getCurrentSize = function () {
|
|
512
|
+
this._currentSize = this._currentSize || "Normal";
|
|
513
|
+
var oSettings = this.getSettings();
|
|
514
|
+
if (oSettings.preview.position && (oSettings.preview.position === "top" || oSettings.preview.position === "bottom" || oSettings.preview.position === "separate")) {
|
|
515
|
+
this._currentSize = "Full";
|
|
516
|
+
}
|
|
517
|
+
return this._currentSize;
|
|
518
|
+
};
|
|
519
|
+
|
|
520
|
+
/**
|
|
521
|
+
* toggles the current mode from "Full" to "Nomal" and vice versa
|
|
522
|
+
*/
|
|
523
|
+
CardPreview.prototype._toggleCurrentSize = function () {
|
|
524
|
+
this._currentSize = this._currentSize !== "Normal" ? "Normal" : "Full";
|
|
525
|
+
if (this._currentSize === "Normal") {
|
|
526
|
+
this.getEditor().setWidth(this.getParentWidth());
|
|
527
|
+
document.body.style.removeProperty("--sapUiIntegrationEditorPreviewWidth");
|
|
528
|
+
document.body.style.removeProperty("--sapUiIntegrationEditorPreviewHeight");
|
|
529
|
+
} else {
|
|
530
|
+
this.getEditor().setWidth("0");
|
|
531
|
+
document.body.style.setProperty("--sapUiIntegrationEditorPreviewWidth", this.getParentWidth());
|
|
532
|
+
document.body.style.setProperty("--sapUiIntegrationEditorPreviewHeight", this.getParentHeight());
|
|
533
|
+
}
|
|
534
|
+
};
|
|
535
|
+
|
|
536
|
+
/**
|
|
537
|
+
* toggles the current size from "Full" to "Normal" and vice versa
|
|
538
|
+
* @returns {sap.m.ToggleButton}
|
|
539
|
+
*/
|
|
540
|
+
CardPreview.prototype._getResizeToggleButton = function () {
|
|
541
|
+
var oBundle = Core.getLibraryResourceBundle("sap.ui.integration");
|
|
542
|
+
|
|
543
|
+
if (!this._oSizeToggleButton) {
|
|
544
|
+
this._oSizeToggleButton = new ToggleButton();
|
|
545
|
+
this._oSizeToggleButton.setTooltip();
|
|
546
|
+
this._oSizeToggleButton.attachPress(function () {
|
|
547
|
+
this._toggleCurrentSize();
|
|
548
|
+
this.update();
|
|
549
|
+
this.getDomRef("before").focus();
|
|
550
|
+
}.bind(this));
|
|
551
|
+
}
|
|
552
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButton");
|
|
553
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonSpec");
|
|
554
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonFull");
|
|
555
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonFullSpec");
|
|
556
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonOnly");
|
|
557
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonOnlySpec");
|
|
558
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonOnlyFull");
|
|
559
|
+
this._oSizeToggleButton.removeStyleClass("sapUiIntegrationDTPreviewResizeButtonOnlyFullSpec");
|
|
560
|
+
var sLanguge = Core.getConfiguration().getLanguage().replaceAll('_', '-');
|
|
561
|
+
if (this._getModes() === "Mock" || this._getModes() === "Live") {
|
|
562
|
+
if (this._getCurrentSize() === "Full") {
|
|
563
|
+
if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
564
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonOnlyFullSpec");
|
|
565
|
+
} else {
|
|
566
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonOnlyFull");
|
|
567
|
+
}
|
|
568
|
+
} else if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
569
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonOnlySpec");
|
|
570
|
+
} else {
|
|
571
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonOnly");
|
|
572
|
+
}
|
|
573
|
+
} else {
|
|
574
|
+
if (this._getCurrentSize() === "Full") {
|
|
575
|
+
if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
576
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonFullSpec");
|
|
577
|
+
} else {
|
|
578
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonFull");
|
|
579
|
+
}
|
|
580
|
+
} else if (sLanguge.startsWith("ar") || sLanguge.startsWith("he")) {
|
|
581
|
+
// for the languages "ar-SA"(Arabic) and "he-IL"(Hebrew) which write from right to left, use spec style
|
|
582
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButtonSpec");
|
|
583
|
+
} else {
|
|
584
|
+
this._oSizeToggleButton.addStyleClass("sapUiIntegrationDTPreviewResizeButton");
|
|
585
|
+
}
|
|
586
|
+
}
|
|
587
|
+
var tb = this._oSizeToggleButton,
|
|
588
|
+
currentMode = this._getCurrentMode(),
|
|
589
|
+
currenSize = this._getCurrentSize();
|
|
590
|
+
if (currentMode === "None") {
|
|
591
|
+
tb.setVisible(false);
|
|
592
|
+
}
|
|
593
|
+
if (currenSize === "Normal") {
|
|
594
|
+
tb.setIcon("sap-icon://full-screen");
|
|
595
|
+
tb.setPressed(false);
|
|
596
|
+
tb.setTooltip(oBundle.getText("CARDEDITOR_PREVIEW_BTN_FULLSIZE"));
|
|
597
|
+
} else if (currenSize === "Full") {
|
|
598
|
+
tb.setIcon("sap-icon://exit-full-screen");
|
|
599
|
+
tb.setPressed(true);
|
|
600
|
+
tb.setTooltip(oBundle.getText("CARDEDITOR_PREVIEW_BTN_NORMALSIZE"));
|
|
601
|
+
}
|
|
602
|
+
return this._oSizeToggleButton;
|
|
603
|
+
};
|
|
604
|
+
|
|
439
605
|
/**
|
|
440
606
|
* updates this preview
|
|
441
607
|
*/
|
|
@@ -456,36 +622,6 @@ sap.ui.define([
|
|
|
456
622
|
return (yiq <= 128);
|
|
457
623
|
}
|
|
458
624
|
|
|
459
|
-
CardPreview.prototype.onfocusin = function (oEvent) {
|
|
460
|
-
if (!this.getSettings().preview.interactive) {
|
|
461
|
-
if (!this._focusinByTabPrevious && oEvent.srcControl !== this._oModeToggleButton) {
|
|
462
|
-
if (this._oModeToggleButton) {
|
|
463
|
-
this._oModeToggleButton.focus();
|
|
464
|
-
} else {
|
|
465
|
-
this.getDomRef("after").focus();
|
|
466
|
-
}
|
|
467
|
-
}
|
|
468
|
-
this._focusinByTabPrevious = false;
|
|
469
|
-
}
|
|
470
|
-
};
|
|
471
|
-
|
|
472
|
-
CardPreview.prototype.onsaptabnext = function (oEvent) {
|
|
473
|
-
if (!this.getSettings().preview.interactive) {
|
|
474
|
-
if (oEvent.srcControl !== this._oModeToggleButton) {
|
|
475
|
-
this.getDomRef("after").focus();
|
|
476
|
-
}
|
|
477
|
-
}
|
|
478
|
-
};
|
|
479
|
-
|
|
480
|
-
CardPreview.prototype.onsaptabprevious = function (oEvent) {
|
|
481
|
-
if (!this.getSettings().preview.interactive) {
|
|
482
|
-
this._focusinByTabPrevious = true;
|
|
483
|
-
if (!this._oModeToggleButton || oEvent.srcControl === this._oModeToggleButton) {
|
|
484
|
-
this.getDomRef("before").focus();
|
|
485
|
-
}
|
|
486
|
-
}
|
|
487
|
-
};
|
|
488
|
-
|
|
489
625
|
CardPreview.init = function () {
|
|
490
626
|
var sCssURL = sap.ui.require.toUrl("sap.ui.integration.designtime.editor.css.CardPreview".replace(/\./g, "/") + ".css");
|
|
491
627
|
includeStylesheet(sCssURL);
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* OpenUI5
|
|
3
|
+
* (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
sap.ui.define([
|
|
8
|
+
"sap/ui/integration/widgets/CardRenderer",
|
|
9
|
+
"sap/f/library"
|
|
10
|
+
], function (WidgetsCardRenderer, library) {
|
|
11
|
+
"use strict";
|
|
12
|
+
var HeaderPosition = library.cards.HeaderPosition;
|
|
13
|
+
|
|
14
|
+
return WidgetsCardRenderer.extend("sap.ui.integration.designtime.editor.CardRenderer", {
|
|
15
|
+
apiVersion: 2,
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* @override
|
|
19
|
+
*/
|
|
20
|
+
render: function (oRm, oCard) {
|
|
21
|
+
var oHeader = oCard.getCardHeader(),
|
|
22
|
+
bHeaderTop = oHeader && oCard.getCardHeaderPosition() === HeaderPosition.Top;
|
|
23
|
+
|
|
24
|
+
oRm.openStart("div", oCard);
|
|
25
|
+
this.renderContainerAttributes(oRm, oCard);
|
|
26
|
+
oRm.openEnd();
|
|
27
|
+
|
|
28
|
+
// add readonly
|
|
29
|
+
if (oCard.getReadonly()) {
|
|
30
|
+
oRm.openStart("div", oCard.getId() + "-readonly");
|
|
31
|
+
oRm.attr("tabindex", "-1");
|
|
32
|
+
oRm.style("z-index", oCard.getReadonlyZIndex());
|
|
33
|
+
oRm.style("position", "absolute");
|
|
34
|
+
oRm.style("width", "100%");
|
|
35
|
+
oRm.style("height", "100%");
|
|
36
|
+
oRm.style("opacity", "0.01");
|
|
37
|
+
oRm.style("background-color", "rgba(222, 222, 222, 0.5)");
|
|
38
|
+
oRm.openEnd();
|
|
39
|
+
oRm.close("div");
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
// header at the top
|
|
43
|
+
if (bHeaderTop) {
|
|
44
|
+
oRm.renderControl(oHeader);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// content
|
|
48
|
+
this.renderContentSection(oRm, oCard);
|
|
49
|
+
|
|
50
|
+
// header at the bottom
|
|
51
|
+
if (!bHeaderTop) {
|
|
52
|
+
oRm.renderControl(oHeader);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
// footer
|
|
56
|
+
this.renderFooterSection(oRm, oCard);
|
|
57
|
+
|
|
58
|
+
oRm.renderControl(oCard._ariaText);
|
|
59
|
+
oRm.renderControl(oCard._ariaContentText);
|
|
60
|
+
|
|
61
|
+
oRm.close("div");
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
});
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
.sapUiIntegrationDTPreview {
|
|
2
2
|
padding: 0.5rem;
|
|
3
|
-
overflow:
|
|
3
|
+
overflow: auto;
|
|
4
4
|
min-width: calc(190px + 5rem);
|
|
5
|
-
width: calc(190px + 5rem);
|
|
6
|
-
height: 350px;
|
|
5
|
+
width: var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 5rem));
|
|
6
|
+
height: var(--sapUiIntegrationEditorPreviewHeight, 350px);
|
|
7
7
|
box-sizing: border-box;
|
|
8
8
|
display: inline-block;
|
|
9
9
|
background-color: rgba(222, 222, 222, 0.3) !important;
|
|
@@ -11,23 +11,25 @@
|
|
|
11
11
|
border-radius: 2px;
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
.
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
.sapUiIntegrationDTPreview.sapUiIntegrationDTPreviewSeparate {
|
|
15
|
+
width: auto;
|
|
16
|
+
height: auto;
|
|
17
|
+
display: block;
|
|
17
18
|
}
|
|
18
19
|
|
|
19
|
-
.
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
.sapUiIntegrationDTPreview::-webkit-scrollbar {
|
|
21
|
+
width: 7px !important;
|
|
22
|
+
background-color: transparent !important ;
|
|
23
|
+
transition: all 0.5s ease-in;
|
|
22
24
|
}
|
|
23
25
|
|
|
24
|
-
.sapUiIntegrationDTPreview
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
26
|
+
.sapUiIntegrationDTPreview::-webkit-scrollbar-thumb {
|
|
27
|
+
background-color: transparent !important;
|
|
28
|
+
width: 7px;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.sapUiIntegrationDTPreview:hover::-webkit-scrollbar-thumb {
|
|
32
|
+
background-color: var(--sapUiChartScrollbarBorderColor, rgba(148, 148, 148, 0.4))!important;
|
|
31
33
|
}
|
|
32
34
|
|
|
33
35
|
.sapUiIntegrationDTPreview.sapUiIntegrationDTPreviewDark {
|
|
@@ -37,10 +39,18 @@
|
|
|
37
39
|
|
|
38
40
|
.sapUiIntegrationDTPreview.sapUiIntegrationDTPreviewDark .sapUiIntegrationDTPreviewImg {
|
|
39
41
|
opacity: 0.2;
|
|
42
|
+
width: var(--sapUiIntegrationEditorPreviewWidth, calc(400px + 10rem)) !important;
|
|
43
|
+
height: var(--sapUiIntegrationEditorPreviewHeight, calc(700px - 1.5rem)) !important;
|
|
40
44
|
}
|
|
41
45
|
|
|
42
46
|
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewImg {
|
|
43
47
|
opacity: 1;
|
|
48
|
+
width: var(--sapUiIntegrationEditorPreviewWidth, calc(400px + 10rem)) !important;
|
|
49
|
+
height: var(--sapUiIntegrationEditorPreviewHeight, calc(700px - 1.5rem)) !important;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewImgHBox {
|
|
53
|
+
width: var(--sapUiIntegrationEditorPreviewWidth, calc(400px + 10rem)) !important;
|
|
44
54
|
}
|
|
45
55
|
|
|
46
56
|
.sapUiIntegrationDTPreview .sapFCard.sapUiIntegrationDTPreviewScale {
|
|
@@ -59,12 +69,64 @@
|
|
|
59
69
|
position: absolute
|
|
60
70
|
}
|
|
61
71
|
|
|
62
|
-
.sapUiIntegrationDTPreview .
|
|
72
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewModeButton {
|
|
73
|
+
position: absolute !important;
|
|
74
|
+
margin: calc(350px - 2.8rem) 0 0 calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 15.5rem))/2 - 8rem) !important;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewModeButtonSpec {
|
|
78
|
+
position: absolute !important;
|
|
79
|
+
margin: calc(350px - 2.8rem) calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 15.5rem))/2 - 8rem) 0 0 !important
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewModeButtonFull {
|
|
83
|
+
margin: 0.5rem 0 0 calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 1rem))/2 - 2.5rem) !important;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewModeButtonFullSpec {
|
|
87
|
+
margin: 0.5rem calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 1rem))/2 - 2.5rem) 0 0 !important;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewModeButtonVerticalFull {
|
|
91
|
+
margin: 0.5rem 0 0 calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px - 2rem))/2 - 1rem) !important;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewModeButtonVerticalFullSpec {
|
|
95
|
+
margin: 0.5rem calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px - 2rem))/2 - 1rem) 0 0 !important;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButton {
|
|
63
99
|
position: absolute !important;
|
|
64
|
-
margin: calc(350px - 2.8rem) 0 0 calc(
|
|
100
|
+
margin: calc(350px - 2.8rem) 0 0 calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 15.5rem))/2 - 5rem) !important;
|
|
65
101
|
}
|
|
66
102
|
|
|
67
|
-
.sapUiIntegrationDTPreview .
|
|
103
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonSpec {
|
|
68
104
|
position: absolute !important;
|
|
69
|
-
margin:calc(350px - 2.8rem) calc(
|
|
105
|
+
margin: calc(350px - 2.8rem) calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 15.5rem))/2 - 5rem) 0 0 !important
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonFull {
|
|
109
|
+
margin: 0.5rem 0 0 1rem !important;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonFullSpec {
|
|
113
|
+
margin: 0.5rem 1rem 0 0 !important;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonOnly {
|
|
117
|
+
position: absolute !important;
|
|
118
|
+
margin: calc(350px - 2.8rem) 0 0 calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 15.5rem))/2 - 6.5rem) !important;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonOnlySpec {
|
|
122
|
+
position: absolute !important;
|
|
123
|
+
margin: calc(350px - 2.8rem) calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px + 15.5rem))/2 - 6.5rem) 0 0 !important
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonOnlyFull {
|
|
127
|
+
margin: 0.5rem 0 0 calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px - 2rem))/2 - 1rem) !important;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.sapUiIntegrationDTPreview .sapUiIntegrationDTPreviewResizeButtonOnlyFullSpec {
|
|
131
|
+
margin: 0.5rem calc(var(--sapUiIntegrationEditorPreviewWidth, calc(190px - 2rem))/2 - 1rem) 0 0 !important;
|
|
70
132
|
}
|