Skip to content

Commit c4cf2fd

Browse files
authored
Collection of bug fixes for the 2.4.2 release (#744)
* Fixed issue where table action rule creation modal displayed invalid suggestions * Add support for links in table actions, as well as improved rendering of links in markdown * No longer rendering empty buttons for missing values in table actions * Fix number formatting to always use en-US locale * Fixed issue where dashboard database was not set correctly for share links without credentials * Fixed dashboard title visibility in sidebar * Added missing setting to pie chart configuration * Clean up code, remove old console.log statements * Stability and UX for table checkbox actiosn * Handling shared dashboards in standalone mode * Added hidden setting for hiding the plaintext password warning. Fixed issue with casting null dates * Style tweaks for reports without footers * Fixed styling defaults for bar chart * Fixed fullscreen views * Freetext parameter with manual save style fixes * clean up graph editing modal * Correction to release notes * Robustness of actions rule create modal * Improved comments
1 parent 9a541b3 commit c4cf2fd

24 files changed

+111
-54
lines changed

changelog.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ This is a release with a large amount of quality of life improvements, as well a
66
- Added parameter select setting for autopopulating first selector value. [#746](https://github.com/neo4j-labs/neodash/pull/746)
77
- Improved UX for editing page names & dashboard titles. [#743](https://github.com/neo4j-labs/neodash/pull/743)
88
- Unified common settings for each report type. [#724](https://github.com/neo4j-labs/neodash/pull/724)
9-
- SSO auth tokens are now automatically refreshed on expiry. [#611](https://github.com/neo4j-labs/neodash/pull/611)
109
- Title of the browser tab NeoDash runs on is now automatically set to the dashboard name. [#708](https://github.com/neo4j-labs/neodash/pull/708)
1110
- Fixed issue where invisible table columns were not handled correctly. [#695](https://github.com/neo4j-labs/neodash/pull/695)
1211
- Miscellaneous bug fixes, style improvements & stability fixes. [#744](https://github.com/neo4j-labs/neodash/pull/744)
1312

13+
1414
## NeoDash 2.4.1
1515
This is a patch release following 2.4.0. It contains several new features for self-hosted (standalone) NeoDash deployments, as well as a variety of UX improvements for dashboard editors.
1616

public/style.css

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@
9595
}
9696

9797
.react-resizable-handle {
98-
bottom: 1px !important;
98+
bottom: 4px !important;
99+
right: -2px !important;
99100
opacity: 0.5;
100101
color: rgb(222, 222, 222);
101102
}
@@ -216,7 +217,7 @@
216217
}
217218

218219
.card-view .MuiTablePagination-root {
219-
margin-top: -40px;
220+
margin-top: 0px;
220221

221222
}
222223

@@ -253,3 +254,7 @@
253254
display: none;
254255
}
255256
/* End Gantt chart workaround */
257+
258+
.markdown-widget a {
259+
text-decoration: underline;
260+
}

release-notes.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ This is a release with a large amount of quality of life improvements, as well a
66
- Added parameter select setting for autopopulating first selector value. [#746](https://github.com/neo4j-labs/neodash/pull/746)
77
- Improved UX for editing page names & dashboard titles. [#743](https://github.com/neo4j-labs/neodash/pull/743)
88
- Unified common settings for each report type. [#724](https://github.com/neo4j-labs/neodash/pull/724)
9-
- SSO auth tokens are now automatically refreshed on expiry. [#611](https://github.com/neo4j-labs/neodash/pull/611)
109
- Title of the browser tab NeoDash runs on is now automatically set to the dashboard name. [#708](https://github.com/neo4j-labs/neodash/pull/708)
1110
- Fixed issue where invisible table columns were not handled correctly. [#695](https://github.com/neo4j-labs/neodash/pull/695)
1211
- Miscellaneous bug fixes, style improvements & stability fixes. [#744](https://github.com/neo4j-labs/neodash/pull/744)

src/application/ApplicationActions.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ export const setStandaloneEnabled = (
150150
standaloneDashboardURL: string,
151151
standaloneUsername: string,
152152
standalonePassword: string,
153+
standalonePasswordWarningHidden: boolean,
153154
standaloneAllowLoad: boolean,
154155
standaloneLoadFromOtherDatabases: boolean,
155156
standaloneMultiDatabase: boolean,
@@ -167,6 +168,7 @@ export const setStandaloneEnabled = (
167168
standaloneDashboardURL,
168169
standaloneUsername,
169170
standalonePassword,
171+
standalonePasswordWarningHidden,
170172
standaloneAllowLoad,
171173
standaloneLoadFromOtherDatabases,
172174
standaloneMultiDatabase,

src/application/ApplicationReducer.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,7 @@ export const applicationReducer = (state = initialState, action: { type: any; pa
195195
standaloneDashboardURL,
196196
standaloneUsername,
197197
standalonePassword,
198+
standalonePasswordWarningHidden,
198199
standaloneAllowLoad,
199200
standaloneLoadFromOtherDatabases,
200201
standaloneMultiDatabase,
@@ -211,6 +212,7 @@ export const applicationReducer = (state = initialState, action: { type: any; pa
211212
standaloneDashboardURL: standaloneDashboardURL,
212213
standaloneUsername: standaloneUsername,
213214
standalonePassword: standalonePassword,
215+
standalonePasswordWarningHidden: standalonePasswordWarningHidden,
214216
standaloneAllowLoad: standaloneAllowLoad,
215217
standaloneLoadFromOtherDatabases: standaloneLoadFromOtherDatabases,
216218
standaloneMultiDatabase: standaloneMultiDatabase,

src/application/ApplicationSelectors.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ export const applicationGetStandaloneSettings = (state: any) => {
9494
standaloneDashboardURL: state.application.standaloneDashboardURL,
9595
standaloneUsername: state.application.standaloneUsername,
9696
standalonePassword: state.application.standalonePassword,
97+
standalonePasswordWarningHidden: state.application.standalonePasswordWarningHidden,
9798
standaloneAllowLoad: state.application.standaloneAllowLoad,
9899
standaloneLoadFromOtherDatabases: state.application.standaloneLoadFromOtherDatabases,
99100
standaloneMultiDatabase: state.application.standaloneMultiDatabase,

src/application/ApplicationThunks.ts

Lines changed: 30 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -259,26 +259,42 @@ export const handleSharedDashboardsThunk = () => (dispatch: any) => {
259259
const skipConfirmation = urlParams.get('skipConfirmation') == 'Yes';
260260

261261
const dashboardDatabase = urlParams.get('dashboardDatabase');
262+
dispatch(setStandaloneDashboardDatabase(dashboardDatabase));
262263
if (urlParams.get('credentials')) {
264+
setWelcomeScreenOpen(false);
263265
const connection = decodeURIComponent(urlParams.get('credentials'));
264266
const protocol = connection.split('://')[0];
265267
const username = connection.split('://')[1].split(':')[0];
266268
const password = connection.split('://')[1].split(':')[1].split('@')[0];
267-
268269
const database = connection.split('@')[1].split(':')[0];
269270
const url = connection.split('@')[1].split(':')[1];
270271
const port = connection.split('@')[1].split(':')[2];
271-
if (url == password) {
272-
// Special case where a connect link is generated without a password.
273-
// Here, the format is parsed incorrectly and we open the connection window instead.
274-
275-
dispatch(resetShareDetails());
276-
dispatch(setConnectionProperties(protocol, url, port, database, username.split('@')[0], ''));
277-
dispatch(setWelcomeScreenOpen(false));
278-
dispatch(setConnectionModalOpen(true));
279-
// window.history.pushState({}, document.title, "/");
280-
return;
281-
}
272+
// if (url == password) {
273+
// // Special case where a connect link is generated without a password.
274+
// // Here, the format is parsed incorrectly and we open the connection window instead.
275+
// dispatch(setConnectionProperties(protocol, url, port, database, username.split('@')[0], ''));
276+
// dispatch(
277+
// setShareDetailsFromUrl(
278+
// type,
279+
// id,
280+
// standalone,
281+
// protocol,
282+
// url,
283+
// port,
284+
// database,
285+
// username.split('@')[0],
286+
// '',
287+
// dashboardDatabase,
288+
// true
289+
// )
290+
// );
291+
// setDashboardToLoadAfterConnecting(id);
292+
// window.history.pushState({}, document.title, window.location.pathname);
293+
// dispatch(setConnectionModalOpen(true));
294+
// dispatch(setWelcomeScreenOpen(false));
295+
// // window.history.pushState({}, document.title, "/");
296+
// return;
297+
// }
282298

283299
dispatch(setConnectionModalOpen(false));
284300
dispatch(
@@ -448,6 +464,7 @@ export const loadApplicationConfigThunk = () => async (dispatch: any, getState:
448464
config.standaloneDashboardURL,
449465
config.standaloneUsername,
450466
config.standalonePassword,
467+
config.standalonePasswordWarningHidden,
451468
config.standaloneAllowLoad,
452469
config.standaloneLoadFromOtherDatabases,
453470
config.standaloneMultiDatabase,
@@ -605,7 +622,6 @@ export const initializeApplicationAsStandaloneThunk =
605622
(config, paramsToSetAfterConnecting) => (dispatch: any, getState: any) => {
606623
const clearNotificationAfterLoad = true;
607624
const state = getState();
608-
609625
// If we are running in standalone mode, auto-set the connection details that are configured.
610626
dispatch(
611627
setConnectionProperties(
@@ -648,4 +664,5 @@ export const initializeApplicationAsStandaloneThunk =
648664
} else {
649665
dispatch(setConnectionModalOpen(true));
650666
}
667+
dispatch(handleSharedDashboardsThunk());
651668
};

src/card/Card.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ const NeoCard = ({
209209
if (expanded) {
210210
return (
211211
<Dialog open={expanded} aria-labelledby='form-dialog-title' className='dialog-xxl'>
212-
<Dialog.Content style={{ height: document.documentElement.clientHeight }}>{component}</Dialog.Content>
212+
<Dialog.Content style={{ height: document.documentElement.clientHeight - 200 }}>{component}</Dialog.Content>
213213
</Dialog>
214214
);
215215
}

src/card/settings/CardSettings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ const NeoCardSettings = ({
3636
expanded,
3737
onToggleCardExpand,
3838
}) => {
39-
const reportHeight = heightPx - CARD_HEADER_HEIGHT + 24;
39+
const reportHeight = heightPx - CARD_HEADER_HEIGHT + 19;
4040

4141
const cardSettingsHeader = (
4242
<NeoCardSettingsHeader

src/card/view/CardView.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const NeoCardView = ({
4444
expanded,
4545
onToggleCardExpand,
4646
}) => {
47-
const reportHeight = heightPx - CARD_FOOTER_HEIGHT - CARD_HEADER_HEIGHT + 22;
47+
const reportHeight = heightPx - CARD_FOOTER_HEIGHT - CARD_HEADER_HEIGHT + 20;
4848
const cardHeight = heightPx - CARD_FOOTER_HEIGHT + 23;
4949
const ref = React.useRef();
5050

@@ -137,10 +137,10 @@ const NeoCardView = ({
137137

138138
const localParameters = { ...getLocalParameters(query), ...getLocalParameters(settings.drilldownLink) };
139139
const reportTypes = getReportTypes(extensions);
140-
const withoutFooter =
141-
reportTypes[type] && reportTypes[type].withoutFooter
142-
? reportTypes[type].withoutFooter
143-
: (reportTypes[type] && !reportTypes[type].selection) || (settings && settings.hideSelections);
140+
const reportTypeHasNoFooter = reportTypes[type] && reportTypes[type].withoutFooter;
141+
const withoutFooter = reportTypeHasNoFooter
142+
? reportTypes[type].withoutFooter
143+
: (reportTypes[type] && !reportTypes[type].selection) || (settings && settings.hideSelections);
144144

145145
const getGlobalParameter = (key: string): unknown => {
146146
return globalParameters ? globalParameters[key] : undefined;
@@ -170,13 +170,13 @@ const NeoCardView = ({
170170
paddingRight: '0px',
171171
paddingTop: '0px',
172172
width: '100%',
173-
marginTop: '-3px',
173+
marginTop: '-9px',
174174
height: expanded
175175
? withoutFooter
176176
? '100%'
177177
: `calc(100% - ${CARD_FOOTER_HEIGHT}px)`
178178
: withoutFooter
179-
? `${reportHeight + CARD_FOOTER_HEIGHT}px`
179+
? `${reportHeight + CARD_FOOTER_HEIGHT - (reportTypeHasNoFooter ? 0 : 20)}px`
180180
: `${reportHeight}px`,
181181
overflow: 'auto',
182182
};

0 commit comments

Comments
 (0)