@searpent/react-image-annotate 2.0.69 → 2.0.71

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1182,6 +1182,7 @@ export default (function (state, action) {
1182
1182
  value = action.value,
1183
1183
  _imageIndex = action.imageIndex,
1184
1184
  _groupId2 = action.groupId;
1185
+ console.log(action);
1185
1186
 
1186
1187
  if (isNaN(_imageIndex)) {
1187
1188
  var _state$albumMetadata;
@@ -13,10 +13,14 @@ var MetadataItemDiv = styled("div")(function (_ref) {
13
13
  "& > label": {
14
14
  fontSize: "1rem",
15
15
  marginBottom: ".5em",
16
- textTransform: "capitalize"
16
+ textTransform: "capitalize",
17
+ wordWrap: "break-word"
17
18
  },
18
19
  label: {
19
20
  width: "50%"
21
+ },
22
+ select: {
23
+ width: "100%"
20
24
  }
21
25
  };
22
26
  });
@@ -47,13 +51,20 @@ var MetadataItem = function MetadataItem(_ref2) {
47
51
 
48
52
  return React.createElement(MetadataItemDiv, null, React.createElement("label", {
49
53
  for: name
50
- }, name), React.createElement("div", null, (metadataConfig === null || metadataConfig === void 0 ? void 0 : metadataConfig.selectable) !== true && React.createElement(React.Fragment, null, React.createElement("input", {
54
+ }, name), React.createElement("div", {
55
+ style: {
56
+ width: "50%"
57
+ }
58
+ }, (metadataConfig === null || metadataConfig === void 0 ? void 0 : metadataConfig.selectable) !== true && React.createElement(React.Fragment, null, React.createElement("input", {
51
59
  type: "text",
52
60
  value: value,
53
61
  name: name,
54
62
  onChange: handleChange,
55
63
  id: name,
56
- list: "".concat(name, "-list")
64
+ list: "".concat(name, "-list"),
65
+ style: {
66
+ width: "100%"
67
+ }
57
68
  }), React.createElement("datalist", {
58
69
  id: "".concat(name, "-list")
59
70
  }, metadataConfig === null || metadataConfig === void 0 ? void 0 : (_metadataConfig$optio = metadataConfig.options) === null || _metadataConfig$optio === void 0 ? void 0 : _metadataConfig$optio.map(function (opt) {
@@ -71,12 +82,16 @@ var MetadataItem = function MetadataItem(_ref2) {
71
82
  }))), (metadataConfig === null || metadataConfig === void 0 ? void 0 : metadataConfig.selectable) === true && React.createElement("select", {
72
83
  name: name,
73
84
  id: name,
74
- onChange: handleChange
85
+ onChange: handleChange,
86
+ style: {
87
+ width: '100%'
88
+ }
75
89
  }, metadataConfig === null || metadataConfig === void 0 ? void 0 : (_metadataConfig$optio2 = metadataConfig.options) === null || _metadataConfig$optio2 === void 0 ? void 0 : _metadataConfig$optio2.map(function (opt) {
76
90
  if (opt.value && opt.label) {
77
91
  return React.createElement("option", {
78
92
  key: opt.value,
79
- value: opt.value
93
+ value: opt.value,
94
+ selected: opt.value === value
80
95
  }, opt.label);
81
96
  }
82
97
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@searpent/react-image-annotate",
3
- "version": "2.0.69",
3
+ "version": "2.0.71",
4
4
  "dependencies": {
5
5
  "@editorjs/editorjs": "^2.25.0",
6
6
  "@editorjs/paragraph": "^2.8.0",