Skip to content

Commit 2c51dbe

Browse files
authored
Fixes template prop (#308)
* Fixes templates prop * Fix broken test
1 parent 1a9b20f commit 2c51dbe

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

frontend/src/js/components/PlotInspector/PlotInspectorWrapper.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ const mapStateToProps = (state) => {
175175
all_graphics_methods: state.present.graphics_methods,
176176
variables: state.present.variables ? Object.keys(state.present.variables) : [],
177177
graphics_method_types: state.present.graphics_methods ? Object.keys(state.present.graphics_methods) : [],
178-
templates: state.present.templates.names ? state.present.templates.names : [],
178+
templates: state.present.templates ? state.present.templates : [],
179179
}
180180
}
181181

frontend/test/mocha/components/PlotInspector/PlotInspectorWrapperTest.jsx

+4-3
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,10 @@ describe('PlotInspectorWrapperTest.jsx', function() {
189189
variables: {
190190
clt: {},
191191
},
192-
templates: {
193-
names: ["default", "quick"]
194-
},
192+
templates: [
193+
"default",
194+
"quick"
195+
],
195196
sheets_model: {
196197
selected_cell_id: "0_0_0",
197198
sheets: [{

0 commit comments

Comments
 (0)