Remove optionality of toolslot.pullout_direction
parent
6f1af5553c
commit
f70ff09b3d
|
@ -86,7 +86,8 @@ export function fakeToolSlot(): TaggedToolSlotPointer {
|
|||
y: 10,
|
||||
z: 10,
|
||||
radius: 10,
|
||||
meta: {}
|
||||
meta: {},
|
||||
pullout_direction: 0
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -218,6 +218,7 @@ const tr11: TaggedPoint = {
|
|||
},
|
||||
"name": "Slot One.",
|
||||
"pointer_type": "ToolSlot",
|
||||
"pullout_direction": 0,
|
||||
"radius": 25,
|
||||
"x": 10,
|
||||
"y": 10,
|
||||
|
|
|
@ -66,7 +66,7 @@ describe("<ToolSlotPoint/>", () => {
|
|||
|
||||
it("doesn't render toolbay slot", () => {
|
||||
const p = fakeProps();
|
||||
p.slot.toolSlot.body.pullout_direction = undefined;
|
||||
p.slot.toolSlot.body.pullout_direction = 0;
|
||||
const wrapper = shallow(<ToolSlotPoint {...p } />);
|
||||
expect(wrapper.find("use").length).toEqual(0);
|
||||
});
|
||||
|
|
|
@ -27,7 +27,8 @@ describe("<ToolSlotLayer/>", () => {
|
|||
x: 1,
|
||||
y: 2,
|
||||
z: 3,
|
||||
meta: {}
|
||||
meta: {},
|
||||
pullout_direction: 0
|
||||
};
|
||||
const toolSlot = fakeResource("Point", ts);
|
||||
return {
|
||||
|
|
|
@ -103,7 +103,7 @@ export enum ToolPulloutDirection {
|
|||
export interface ToolSlotPointer extends BasePoint {
|
||||
tool_id: number | undefined;
|
||||
pointer_type: "ToolSlot";
|
||||
pullout_direction?: ToolPulloutDirection;
|
||||
pullout_direction: ToolPulloutDirection;
|
||||
}
|
||||
|
||||
export interface GenericPointer extends BasePoint {
|
||||
|
|
|
@ -34,7 +34,8 @@ const fakeSlot: TaggedToolSlotPointer = {
|
|||
z: 0,
|
||||
name: "wow",
|
||||
pointer_id: SLOT_ID,
|
||||
meta: {}
|
||||
meta: {},
|
||||
pullout_direction: 0
|
||||
}
|
||||
};
|
||||
const fakeIndex = buildResourceIndex().index;
|
||||
|
|
|
@ -47,7 +47,8 @@ export function fakeResourceIndex(): ResourceIndex {
|
|||
"x": 100,
|
||||
"y": 200,
|
||||
"z": 300,
|
||||
"tool_id": 1
|
||||
"tool_id": 1,
|
||||
"pullout_direction": 0
|
||||
},
|
||||
"uuid": "toolslot"
|
||||
},
|
||||
|
|
|
@ -36,7 +36,8 @@ export class ToolBayForm extends React.Component<ToolBayFormProps, {}> {
|
|||
pointer_type: "ToolSlot",
|
||||
meta: {},
|
||||
tool_id: undefined,
|
||||
name: "Tool Slot"
|
||||
name: "Tool Slot",
|
||||
pullout_direction: 0
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue