@konfuzio/document-validation-ui 0.1.8-pre-release-1 → 0.1.8-pre-release-2

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@konfuzio/document-validation-ui",
3
- "version": "0.1.8-pre-release-1",
3
+ "version": "0.1.8-pre-release-2",
4
4
  "repository": "git://github.com:konfuzio-ai/document-validation-ui.git",
5
5
  "main": "dist/app.js",
6
6
  "scripts": {
package/src/api.js CHANGED
@@ -21,14 +21,6 @@ const setAuthToken = (token) => {
21
21
  authToken = token;
22
22
  };
23
23
 
24
- const setApiUrl = (url) => {
25
- HTTP.defaults.baseURL = url;
26
- };
27
-
28
- const setImageUrl = (url) => {
29
- IMG_REQUEST.defaults.baseURL = url;
30
- };
31
-
32
24
  const getInterceptorConfig = (config) => {
33
25
  if (authToken) {
34
26
  config.headers["Authorization"] = `Token ${authToken}`;
@@ -62,8 +54,6 @@ const makeImageRequest = (imageURL) => {
62
54
 
63
55
  export default {
64
56
  HTTP,
65
- setApiUrl,
66
- setImageUrl,
67
57
  makeImageRequest,
68
58
  setAuthToken,
69
59
  };
@@ -1,21 +1,9 @@
1
- @use "sass:meta";
2
1
  @import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap");
3
2
  @import "./imports.scss";
4
3
 
5
- :root {
6
- --konfuzio-green: #41af85;
7
- --white: #fff;
8
- --primary-color: var(--konfuzio-green);
9
- --primary-button: 4px;
10
- --top-bar-background: var(--white);
11
- }
12
-
13
- .dv-ui-app-container {
14
- @include meta.load-css("../../../node_modules/buefy/dist/buefy.css");
15
- display: flex;
16
- height: 100%;
17
- flex-direction: column;
4
+ body {
18
5
  margin: 0;
6
+ font-family: $font-family;
19
7
 
20
8
  .overlay {
21
9
  height: 100%;
@@ -28,17 +16,13 @@
28
16
  overflow-x: hidden;
29
17
  }
30
18
 
31
- &.dv-ui-theme {
32
- font-family: $font-family;
33
-
34
- -webkit-font-smoothing: antialiased;
35
- text-rendering: optimizeLegibility;
36
- -webkit-text-size-adjust: 100%;
37
- -moz-text-size-adjust: 100%;
38
- -ms-text-size-adjust: 100%;
39
- text-size-adjust: 100%;
40
- box-sizing: border-box;
19
+ .dv-ui-app-container {
20
+ display: flex;
21
+ height: 100%;
22
+ flex-direction: column;
23
+ }
41
24
 
25
+ .dv-ui-theme {
42
26
  button {
43
27
  &.is-primary {
44
28
  background-color: $primary !important;
@@ -291,7 +275,7 @@
291
275
  }
292
276
 
293
277
  .b-checkbox.checkbox {
294
- input[type="checkbox"] + .check {
278
+ .check {
295
279
  background-color: $white;
296
280
  }
297
281
  &:hover input[type="checkbox"]:not(:disabled) + .check {
@@ -1,3 +1,6 @@
1
+ /* Theme */
2
+
3
+ $konfuzio-green: #41af85;
1
4
  $green: #4bb543;
2
5
  $green-low-opacity: rgba(75, 181, 67, 0.11);
3
6
  $green-border: #67d19f;
@@ -27,7 +30,7 @@ $detail: #e2e3e4;
27
30
  $dark: #2f3032;
28
31
  $full-black: #000;
29
32
 
30
- $white: var(--white);
33
+ $white: #fff;
31
34
  $low-opacity-white: rgba(255, 255, 255, 0.1);
32
35
 
33
36
  $yellow: #ffd600;
@@ -38,6 +41,12 @@ $purple: #7b61ff;
38
41
  $purple-low-opacity: rgba(123, 97, 255, 0.08);
39
42
  $text-color: #1a1a1a;
40
43
 
44
+ :root {
45
+ --primary-color: #{$konfuzio-green};
46
+ --primary-button: 4px;
47
+ --top-bar-background: #{$white};
48
+ }
49
+
41
50
  $primary: var(--primary-color);
42
51
  $hover-style: brightness(0.8) contrast(160%) grayscale(0.4);
43
52
  $font-family: "Inter", sans-serif;
@@ -5,8 +5,6 @@
5
5
  </div>
6
6
  </template>
7
7
  <script>
8
- import Vue from "vue";
9
- import * as Sentry from "@sentry/vue";
10
8
  import DocumentDashboard from "./DocumentDashboard";
11
9
  import { DocumentsList } from "./DocumentsList";
12
10
  import { getURLQueryParam, getURLPath } from "../utils/utils";
@@ -41,30 +39,6 @@ export default {
41
39
  required: false,
42
40
  default: "false",
43
41
  },
44
- // eslint-disable-next-line vue/prop-name-casing
45
- sentry_dsn: {
46
- type: String,
47
- required: false,
48
- default: "",
49
- },
50
- // eslint-disable-next-line vue/prop-name-casing
51
- sentry_env: {
52
- type: String,
53
- required: false,
54
- default: "",
55
- },
56
- // eslint-disable-next-line vue/prop-name-casing
57
- api_url: {
58
- type: String,
59
- required: false,
60
- default: "",
61
- },
62
- // eslint-disable-next-line vue/prop-name-casing
63
- image_url: {
64
- type: String,
65
- required: false,
66
- default: "",
67
- },
68
42
  locale: {
69
43
  type: String,
70
44
  required: false,
@@ -119,40 +93,13 @@ export default {
119
93
  },
120
94
  },
121
95
  created() {
122
- // Sentry config
123
- if (process.env.NODE_ENV != "development") {
124
- Sentry.init({
125
- Vue,
126
- dsn: process.env.VUE_APP_SENTRY_DSN,
127
- integrations: [new Integrations.BrowserTracing()],
128
- environment: process.env.VUE_APP_SENTRY_ENVIRONMENT,
129
-
130
- // We recommend adjusting this value in production, or using tracesSampler
131
- // for finer control
132
- tracesSampleRate: 1.0,
133
-
134
- // If false, errors won't show up in devtools
135
- logErrors: true,
136
-
137
- tracingOptions: {
138
- trackComponents: true,
139
- },
140
- });
141
- }
142
-
143
96
  // locale config
144
97
  if (this.locale && this.locale !== "") {
145
98
  this.$i18n.locale = this.locale;
146
99
  }
147
100
 
148
- // api config
101
+ // user token config
149
102
  API.setAuthToken(this.userToken);
150
- if (this.api_url !== "") {
151
- API.setApiUrl(this.api_url);
152
- }
153
- if (this.image_url !== "") {
154
- API.setImageUrl(this.image_url);
155
- }
156
103
 
157
104
  // document and project config
158
105
  Promise.all([
@@ -181,4 +128,4 @@ export default {
181
128
  };
182
129
  </script>
183
130
 
184
- <style lang="scss" src="../assets/scss/theme.scss"></style>
131
+ <style lang="scss" src="../assets/scss/main.scss"></style>
package/src/main.js CHANGED
@@ -1,5 +1,6 @@
1
1
  import Vue from "vue";
2
2
  import Buefy from "buefy";
3
+ import "buefy/dist/buefy.css";
3
4
  import VueKonva from "vue-konva";
4
5
  import App from "./components/App";
5
6
  import * as Sentry from "@sentry/vue";