Skip to content

Commit

Permalink
build: Release (#2448)
Browse files Browse the repository at this point in the history
  • Loading branch information
mtrezza committed Jun 8, 2023
2 parents 5abcbc9 + 46eee53 commit 8307fc0
Show file tree
Hide file tree
Showing 19 changed files with 481 additions and 53 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -151,3 +151,6 @@ jobs:
run: ./scripts/before_script.sh
env:
CI: true
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
83 changes: 83 additions & 0 deletions changelogs/CHANGELOG_alpha.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,86 @@
# [5.2.0-alpha.11](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.10...5.2.0-alpha.11) (2023-06-08)


### Bug Fixes

* Scroll position is preserved when re-opening the same class in data browser via navigation bar ([#2445](https://github.com/ParsePlatform/parse-dashboard/issues/2445)) ([667675c](https://github.com/ParsePlatform/parse-dashboard/commit/667675c031b0483be210a88da3b159f5f815d6fb))

# [5.2.0-alpha.10](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.9...5.2.0-alpha.10) (2023-06-01)


### Bug Fixes

* Option missing for Parse Config parameter to require master key ([#2440](https://github.com/ParsePlatform/parse-dashboard/issues/2440)) ([6623369](https://github.com/ParsePlatform/parse-dashboard/commit/66233698b333422f306dc7024949aef2ea028f34))

# [5.2.0-alpha.9](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.8...5.2.0-alpha.9) (2023-05-27)


### Bug Fixes

* Dashboard crashes when adding a row with modal in a class that contains a pointer to another class that contains an array of pointers ([#2416](https://github.com/ParsePlatform/parse-dashboard/issues/2416)) ([286269f](https://github.com/ParsePlatform/parse-dashboard/commit/286269f3e2c4e1c83b14003ce72caaf1f39b16c1))

# [5.2.0-alpha.8](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.7...5.2.0-alpha.8) (2023-05-27)


### Bug Fixes

* Cannot navigate to nested relation field in data browser ([#2420](https://github.com/ParsePlatform/parse-dashboard/issues/2420)) ([e7ace9e](https://github.com/ParsePlatform/parse-dashboard/commit/e7ace9efa068b92c5cf0e5ccdad169ac7d71e81a))

# [5.2.0-alpha.7](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.6...5.2.0-alpha.7) (2023-05-27)


### Bug Fixes

* File uploading status not updating in data browser ([#2422](https://github.com/ParsePlatform/parse-dashboard/issues/2422)) ([e761f97](https://github.com/ParsePlatform/parse-dashboard/commit/e761f9715a8366466c6620994ce698adbbfc48cd))

# [5.2.0-alpha.6](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.5...5.2.0-alpha.6) (2023-05-27)


### Bug Fixes

* Text input cursor jumps to first position when writing long text ([#2413](https://github.com/ParsePlatform/parse-dashboard/issues/2413)) ([422ffb2](https://github.com/ParsePlatform/parse-dashboard/commit/422ffb2897bb2664eb47b5aaad5094a8b39431bf))

# [5.2.0-alpha.5](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.4...5.2.0-alpha.5) (2023-05-27)


### Bug Fixes

* Back button in data browser disappears after page refresh ([#2421](https://github.com/ParsePlatform/parse-dashboard/issues/2421)) ([6c5f19f](https://github.com/ParsePlatform/parse-dashboard/commit/6c5f19f6ed2cda1f1f0dc59bdaed3ae49f264380))

# [5.2.0-alpha.4](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.3...5.2.0-alpha.4) (2023-05-27)


### Bug Fixes

* Incorrect date picker position in data browser filter dialog ([#2425](https://github.com/ParsePlatform/parse-dashboard/issues/2425)) ([b96b48f](https://github.com/ParsePlatform/parse-dashboard/commit/b96b48fdd5ce452783e0887c36231971a1822173))

# [5.2.0-alpha.3](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.2...5.2.0-alpha.3) (2023-05-27)


### Bug Fixes

* Empty table in data browser when navigating back using the "back” button ([#2423](https://github.com/ParsePlatform/parse-dashboard/issues/2423)) ([6f3dab6](https://github.com/ParsePlatform/parse-dashboard/commit/6f3dab60c257c76345235acfd3e43aafadeb84c8))

# [5.2.0-alpha.2](https://github.com/ParsePlatform/parse-dashboard/compare/5.2.0-alpha.1...5.2.0-alpha.2) (2023-05-27)


### Features

* Add links to users and roles in ACL dialog and handle invalid entries ([#2436](https://github.com/ParsePlatform/parse-dashboard/issues/2436)) ([a20cb8e](https://github.com/ParsePlatform/parse-dashboard/commit/a20cb8e534d3fecd8d337463864b15048772a9a5))

# [5.2.0-alpha.1](https://github.com/ParsePlatform/parse-dashboard/compare/5.1.0...5.2.0-alpha.1) (2023-05-21)


### Bug Fixes

* Uncaught error when editing Number field in Edit Row dialog ([#2401](https://github.com/ParsePlatform/parse-dashboard/issues/2401)) ([26bd6fa](https://github.com/ParsePlatform/parse-dashboard/commit/26bd6fa39be1076621856a9c86dcd1307f8f7fdd))

### Features

* Add visual configurator for Parse Dashboard settings ([#2406](https://github.com/ParsePlatform/parse-dashboard/issues/2406)) ([228d839](https://github.com/ParsePlatform/parse-dashboard/commit/228d83903fd8698da7b96a5b74699f3ff2d5dad4))
* Data types and pointer classes are sorted alphabetically in dialog to add new column ([#2400](https://github.com/ParsePlatform/parse-dashboard/issues/2400)) ([d9d285b](https://github.com/ParsePlatform/parse-dashboard/commit/d9d285b7f90434d3bb138c2c765272498e3f09c3))
* Sort Cloud Code Jobs alphabetically ([#2402](https://github.com/ParsePlatform/parse-dashboard/issues/2402)) ([77fc372](https://github.com/ParsePlatform/parse-dashboard/commit/77fc372bedb9fb4eca728c1bc076e823c5bc3a2c))

# [5.1.0-alpha.13](https://github.com/ParsePlatform/parse-dashboard/compare/5.1.0-alpha.12...5.1.0-alpha.13) (2023-03-07)


Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "parse-dashboard",
"version": "5.2.0-beta.1",
"version": "5.2.0-alpha.11",
"repository": {
"type": "git",
"url": "https://github.com/ParsePlatform/parse-dashboard"
Expand Down
11 changes: 10 additions & 1 deletion src/components/ACLEditor/ACLEditor.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ import Parse from 'parse';
import PermissionsDialog from 'components/PermissionsDialog/PermissionsDialog.react';
import React from 'react';

function validateEntry(text) {
function validateEntry(text, returnInvalid = true) {

let type = 'unknown';
let entry = text;
let userQuery;
let roleQuery;

Expand All @@ -19,22 +21,26 @@ function validateEntry(text) {
}

if (text.startsWith('user:')) {
type = 'user';
// no need to query roles
roleQuery = {
find: () => Promise.resolve([])
};

let user = text.substring(5);
entry = user;
userQuery = new Parse.Query.or(
new Parse.Query(Parse.User).equalTo('username', user),
new Parse.Query(Parse.User).equalTo('objectId', user)
);
} else if (text.startsWith('role:')) {
type = 'role';
// no need to query users
userQuery = {
find: () => Promise.resolve([])
};
let role = text.substring(5);
entry = role;
roleQuery = new Parse.Query.or(
new Parse.Query(Parse.Role).equalTo('name', role),
new Parse.Query(Parse.Role).equalTo('objectId', role)
Expand All @@ -61,6 +67,9 @@ function validateEntry(text) {
} else if (role.length > 0) {
return { entry: role[0], type: 'role' };
} else {
if(returnInvalid) {
return Promise.resolve({entry, type})
}
return Promise.reject();
}
});
Expand Down
5 changes: 4 additions & 1 deletion src/components/BrowserCell/BrowserCell.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export default class BrowserCell extends Component {
this.copyableValue = this.props.value.id;
}
else if (this.props.type === 'Array') {
if ( this.props.value[0] && typeof this.props.value[0] === 'object' && this.props.value[0].__type === 'Pointer' ) {
if ( this.props.value[0] && typeof this.props.value[0] === 'object' && this.props.value[0].__type === 'Pointer' && typeof this.props.onPointerClick === 'function' ) {
const array = [];
this.props.value.map( (v, i) => {
if ( typeof v !== 'object' || v.__type !== 'Pointer' ) {
Expand Down Expand Up @@ -177,6 +177,9 @@ export default class BrowserCell extends Component {
componentDidUpdate(prevProps) {
if ( this.props.value !== prevProps.value ) {
this.renderCellContent();
this.props.value._previousSave
?.then(() => this.renderCellContent())
?.catch(err => console.log(err))
}
if (this.props.current) {
const node = this.cellRef.current;
Expand Down
9 changes: 6 additions & 3 deletions src/components/BrowserFilter/BrowserFilter.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ export default class BrowserFilter extends React.Component {

this.state = {
open: false,
editMode: true,
filters: new List(),
blacklistedFilters: Filters.BLACKLISTED_FILTERS.concat(props.blacklistedFilters)
};
Expand All @@ -48,7 +49,8 @@ export default class BrowserFilter extends React.Component {
}
this.setState(prevState => ({
open: !prevState.open,
filters: filters
filters: filters,
editMode: this.props.filters.size === 0
}));
this.props.setCurrent(null);
}
Expand All @@ -59,7 +61,8 @@ export default class BrowserFilter extends React.Component {
this.setState(({ filters }) => ({
filters: filters.push(
new Map({ field: field, constraint: available[field][0] })
)
),
editMode: true
}));
}

Expand Down Expand Up @@ -116,7 +119,7 @@ export default class BrowserFilter extends React.Component {
onChange={filters => this.setState({ filters: filters })}
onSearch={this.apply.bind(this)}
renderRow={props => (
<FilterRow {...props} active={this.props.filters.size > 0} parentContentId={POPOVER_CONTENT_ID} />
<FilterRow {...props} active={this.props.filters.size > 0} editMode={this.state.editMode} parentContentId={POPOVER_CONTENT_ID} />
)}
/>
<div className={styles.footer}>
Expand Down
56 changes: 30 additions & 26 deletions src/components/BrowserFilter/FilterRow.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import DateTimeEntry from 'components/DateTimeEntry/DateTimeEntry.react';
import Icon from 'components/Icon/Icon.react';
import Parse from 'parse';
import PropTypes from 'lib/PropTypes';
import React from 'react';
import React, { useCallback } from 'react';
import styles from 'components/BrowserFilter/BrowserFilter.scss';
import validateNumeric from 'lib/validateNumeric';

Expand All @@ -20,13 +20,7 @@ for (let c in Constraints) {
constraintLookup[Constraints[c].name] = c;
}

let setFocus = (input) => {
if (input !== null) {
input.focus();
}
}

function compareValue(info, value, onChangeCompareTo, onKeyDown, active, parentContentId) {
function compareValue(info, value, onChangeCompareTo, onKeyDown, active, parentContentId, setFocus) {
switch (info.type) {
case null:
return null;
Expand Down Expand Up @@ -91,25 +85,35 @@ let FilterRow = ({
onDeleteRow,
active,
parentContentId,
}) => (
<div className={styles.row}>
<ChromeDropdown
color={active ? 'blue' : 'purple'}
value={currentField}
options={fields}
onChange={onChangeField} />
<ChromeDropdown
width={compareInfo.type ? '175' : '325'}
color={active ? 'blue' : 'purple'}
value={Constraints[currentConstraint].name}
options={constraints.map((c) => Constraints[c].name)}
onChange={(c) => onChangeConstraint(constraintLookup[c], compareTo)} />
{compareValue(compareInfo, compareTo, onChangeCompareTo, onKeyDown, active, parentContentId)}
<button type='button' className={styles.remove} onClick={onDeleteRow}><Icon name='minus-solid' width={14} height={14} fill='rgba(0,0,0,0.4)' /></button>
</div>
);
editMode
}) => {

let setFocus = useCallback((input) => {
if (input !== null && editMode) {
input.focus();
}
}, [])

return (
<div className={styles.row}>
<ChromeDropdown
color={active ? 'blue' : 'purple'}
value={currentField}
options={fields}
onChange={onChangeField} />
<ChromeDropdown
width={compareInfo.type ? '175' : '325'}
color={active ? 'blue' : 'purple'}
value={Constraints[currentConstraint].name}
options={constraints.map((c) => Constraints[c].name)}
onChange={(c) => onChangeConstraint(constraintLookup[c], compareTo)} />
{compareValue(compareInfo, compareTo, onChangeCompareTo, onKeyDown, active, parentContentId, setFocus)}
<button type='button' className={styles.remove} onClick={onDeleteRow}><Icon name='minus-solid' width={14} height={14} fill='rgba(0,0,0,0.4)' /></button>
</div>
);
}

export default FilterRow;
export default React.memo(FilterRow);

FilterRow.propTypes = {
fields: PropTypes.arrayOf(PropTypes.string).isRequired,
Expand Down
Loading

0 comments on commit 8307fc0

Please sign in to comment.