@rpg-engine/long-bow 0.2.37 → 0.2.38
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/dist/components/TradingMenu/TradingMenu.d.ts +1 -0
- package/dist/long-bow.cjs.development.js +10 -3
- package/dist/long-bow.cjs.development.js.map +1 -1
- package/dist/long-bow.cjs.production.min.js +1 -1
- package/dist/long-bow.cjs.production.min.js.map +1 -1
- package/dist/long-bow.esm.js +10 -3
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/TradingMenu/TradingMenu.tsx +9 -1
package/package.json
CHANGED
|
@@ -8,6 +8,7 @@ import { TradingItemRow } from './TradingItemRow';
|
|
|
8
8
|
export interface ITrandingMenu {
|
|
9
9
|
traderItems: ITradeResponseItem[];
|
|
10
10
|
onClose: () => void;
|
|
11
|
+
onConfirm: () => void;
|
|
11
12
|
type: TradeTransactionType;
|
|
12
13
|
atlasJSON: any;
|
|
13
14
|
atlasIMG: any;
|
|
@@ -23,6 +24,7 @@ export const TradingMenu: React.FC<ITrandingMenu> = ({
|
|
|
23
24
|
atlasIMG,
|
|
24
25
|
characterAvailableGold,
|
|
25
26
|
onChangeTraderItems,
|
|
27
|
+
onConfirm,
|
|
26
28
|
}) => {
|
|
27
29
|
const [sum, setSum] = useState(0);
|
|
28
30
|
let newSumArray = 0;
|
|
@@ -96,10 +98,16 @@ export const TradingMenu: React.FC<ITrandingMenu> = ({
|
|
|
96
98
|
<Button
|
|
97
99
|
buttonType={ButtonTypes.RPGUIButton}
|
|
98
100
|
disabled={sum > characterAvailableGold}
|
|
101
|
+
onClick={() => onConfirm()}
|
|
99
102
|
>
|
|
100
103
|
Confirm
|
|
101
104
|
</Button>
|
|
102
|
-
<Button
|
|
105
|
+
<Button
|
|
106
|
+
buttonType={ButtonTypes.RPGUIButton}
|
|
107
|
+
onClick={() => onClose()}
|
|
108
|
+
>
|
|
109
|
+
Cancel
|
|
110
|
+
</Button>
|
|
103
111
|
</ButtonWrapper>
|
|
104
112
|
</>
|
|
105
113
|
</DraggableContainer>
|