debian-mirror-gitlab/app/assets/javascripts/visual_review_toolbar/shared/constants.js

57 lines
1.5 KiB
JavaScript
Raw Normal View History

2019-09-04 21:01:54 +05:30
// component selectors
2019-10-12 21:52:04 +05:30
const CHANGE_MR_ID_BUTTON = 'gitlab-change-mr';
2019-09-04 21:01:54 +05:30
const COLLAPSE_BUTTON = 'gitlab-collapse';
const COMMENT_BOX = 'gitlab-comment';
const COMMENT_BUTTON = 'gitlab-comment-button';
2019-09-30 21:07:59 +05:30
const FORM = 'gitlab-form';
const FORM_CONTAINER = 'gitlab-form-wrapper';
2019-10-12 21:52:04 +05:30
const LOGIN = 'gitlab-login-button';
2019-09-04 21:01:54 +05:30
const LOGOUT = 'gitlab-logout-button';
2019-10-12 21:52:04 +05:30
const MR_ID = 'gitlab-submit-mr';
const MR_ID_BUTTON = 'gitlab-submit-mr-button';
2019-09-04 21:01:54 +05:30
const NOTE = 'gitlab-validation-note';
2019-09-30 21:07:59 +05:30
const NOTE_CONTAINER = 'gitlab-note-wrapper';
2019-10-12 21:52:04 +05:30
const REMEMBER_ITEM = 'gitlab-remember-item';
2019-09-04 21:01:54 +05:30
const REVIEW_CONTAINER = 'gitlab-review-container';
const TOKEN_BOX = 'gitlab-token';
2019-10-12 21:52:04 +05:30
// Storage keys
const STORAGE_PREFIX = '--gitlab'; // Using `--` to make the prefix more unique
const STORAGE_MR_ID = `${STORAGE_PREFIX}-merge-request-id`;
const STORAGE_TOKEN = `${STORAGE_PREFIX}-token`;
const STORAGE_COMMENT = `${STORAGE_PREFIX}-comment`;
2019-09-04 21:01:54 +05:30
// colors — these are applied programmatically
// rest of styles belong in ./styles
const BLACK = 'rgba(46, 46, 46, 1)';
const CLEAR = 'rgba(255, 255, 255, 0)';
const MUTED = 'rgba(223, 223, 223, 0.5)';
const RED = 'rgba(219, 59, 33, 1)';
2019-09-30 21:07:59 +05:30
const WHITE = 'rgba(250, 250, 250, 1)';
2019-09-04 21:01:54 +05:30
export {
2019-10-12 21:52:04 +05:30
CHANGE_MR_ID_BUTTON,
2019-09-04 21:01:54 +05:30
COLLAPSE_BUTTON,
COMMENT_BOX,
COMMENT_BUTTON,
FORM,
2019-09-30 21:07:59 +05:30
FORM_CONTAINER,
2019-09-04 21:01:54 +05:30
LOGIN,
LOGOUT,
2019-10-12 21:52:04 +05:30
MR_ID,
MR_ID_BUTTON,
2019-09-04 21:01:54 +05:30
NOTE,
2019-09-30 21:07:59 +05:30
NOTE_CONTAINER,
2019-10-12 21:52:04 +05:30
REMEMBER_ITEM,
2019-09-04 21:01:54 +05:30
REVIEW_CONTAINER,
TOKEN_BOX,
2019-10-12 21:52:04 +05:30
STORAGE_MR_ID,
STORAGE_TOKEN,
STORAGE_COMMENT,
2019-09-04 21:01:54 +05:30
BLACK,
CLEAR,
MUTED,
RED,
WHITE,
};