mirror of
https://github.com/maputnik/editor.git
synced 2026-06-02 05:17:31 +00:00
Fall back to defaut style
This commit is contained in:
@@ -56,7 +56,6 @@ export default class PropertyGroup extends React.Component {
|
||||
padding: margins[2],
|
||||
paddingRight: 0,
|
||||
backgroundColor: colors.black,
|
||||
marginBottom: margins[2],
|
||||
}}>
|
||||
{fields}
|
||||
</div>
|
||||
|
||||
@@ -21,7 +21,6 @@ class LayerSettings extends React.Component {
|
||||
padding: margins[2],
|
||||
paddingRight: 0,
|
||||
backgroundColor: colors.black,
|
||||
marginBottom: margins[2],
|
||||
}}>
|
||||
<InputBlock label={"Layer ID"}>
|
||||
<StringInput
|
||||
|
||||
@@ -9,6 +9,7 @@ import request from 'request'
|
||||
import FileUploadIcon from 'react-icons/lib/md/file-upload'
|
||||
import AddIcon from 'react-icons/lib/md/add-circle-outline'
|
||||
|
||||
import style from '../../libs/style.js'
|
||||
import colors from '../../config/colors'
|
||||
import { margins, fontSizes } from '../../config/scales'
|
||||
import publicStyles from '../../config/styles.json'
|
||||
@@ -75,7 +76,7 @@ class OpenModal extends React.Component {
|
||||
withCredentials: false,
|
||||
}, (error, response, body) => {
|
||||
if (!error && response.statusCode == 200) {
|
||||
const mapStyle = JSON.parse(body)
|
||||
const mapStyle = style.ensureMetadataExists(JSON.parse(body))
|
||||
console.log('Loaded style ', mapStyle.id)
|
||||
this.props.onStyleOpen(mapStyle)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user