@undp/carbon-library 1.0.135-CARBON-343.6 → 1.0.135-CARBON-343.7
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/index.js +10 -4
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +10 -4
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
@@ -23624,7 +23624,7 @@ var EditableCell = function (_a) {
|
|
23624
23624
|
return React.createElement("td", __assign({}, restProps), childNode);
|
23625
23625
|
};
|
23626
23626
|
|
23627
|
-
var css_248z$4 = ".steps-actions {\n display: flex;\n flex-direction: row-reverse;\n margin-right: 1rem; }\n .steps-actions .action-btn {\n border: 1px solid #16b1ff;\n color: #16b1ff;\n margin-right: 1rem; }\n .steps-actions .back-btn {\n border: 1px solid rgba(140, 140, 140, 0.7);\n color: rgba(140, 140, 140, 0.7);\n margin-right: 1rem; }\n .steps-actions .mg-left-1 {\n margin-left: 1rem; }\n";
|
23627
|
+
var css_248z$4 = ".steps-actions {\n display: flex;\n flex-direction: row-reverse;\n margin-right: 1rem;\n justify-content: center; }\n .steps-actions .action-btn {\n border: 1px solid #16b1ff;\n color: #16b1ff;\n margin-right: 1rem; }\n .steps-actions .back-btn {\n border: 1px solid rgba(140, 140, 140, 0.7);\n color: rgba(140, 140, 140, 0.7);\n margin-right: 1rem; }\n .steps-actions .mg-left-1 {\n margin-left: 1rem; }\n";
|
23628
23628
|
styleInject(css_248z$4);
|
23629
23629
|
|
23630
23630
|
var NdcDetailsComponent = function (props) {
|
@@ -23740,6 +23740,11 @@ var NdcDetailsComponent = function (props) {
|
|
23740
23740
|
}
|
23741
23741
|
}
|
23742
23742
|
};
|
23743
|
+
React.useEffect(function () {
|
23744
|
+
if (periodItems && periodItems.length > 1) {
|
23745
|
+
setSelectedTab(periodItems[periodItems.length - 1].key);
|
23746
|
+
}
|
23747
|
+
}, [periodItems]);
|
23743
23748
|
var onDateRangeChanged = function (range) {
|
23744
23749
|
var period = {
|
23745
23750
|
start: Number(moment(range[0]).year()),
|
@@ -23749,9 +23754,9 @@ var NdcDetailsComponent = function (props) {
|
|
23749
23754
|
};
|
23750
23755
|
function addNewPeriodContent() {
|
23751
23756
|
return (React.createElement("div", null,
|
23752
|
-
React.createElement(antd.Row,
|
23757
|
+
React.createElement(antd.Row, { justify: "center" },
|
23753
23758
|
React.createElement(RangePicker, { onChange: onDateRangeChanged, picker: "year" })),
|
23754
|
-
React.createElement(antd.Row, { className: "mg-top-1" },
|
23759
|
+
React.createElement(antd.Row, { className: "mg-top-1", justify: "center" },
|
23755
23760
|
React.createElement("div", { className: "steps-actions" },
|
23756
23761
|
React.createElement(antd.Button, { type: "primary", onClick: onAddNewPeriod, htmlType: "submit", loading: loading }, t("ndc:submit")),
|
23757
23762
|
React.createElement(antd.Button, { className: "back-btn", onClick: onCancelPeriod, loading: loading }, t("ndc:back"))))));
|
@@ -23800,8 +23805,9 @@ var NdcDetailsComponent = function (props) {
|
|
23800
23805
|
selectedTab !== "add_new" && (React.createElement("div", null,
|
23801
23806
|
React.createElement("div", null,
|
23802
23807
|
React.createElement(antd.Table, { components: components, rowClassName: function () { return "editable-row"; }, bordered: true, dataSource: ndcDetailsData, columns: columns, footer: function () { return (React.createElement(antd.Row, { justify: "center" },
|
23803
|
-
React.createElement(antd.Button, { onClick: onAddNewNdcDetail, type: "
|
23808
|
+
React.createElement(antd.Button, { onClick: onAddNewNdcDetail, type: "default", style: {
|
23804
23809
|
marginBottom: 16,
|
23810
|
+
width: '100%'
|
23805
23811
|
} }, t("ndc:addNdcAction")))); } }))))));
|
23806
23812
|
};
|
23807
23813
|
|