Commit Graph

194 Commits

Author SHA1 Message Date
Sam Bigelow bf8ab12433 Default MR checkbox to true in most cases
- Pull the new MR option out into it's own component
- Default MR checkbox to true when creating a new MR and committing to a
  branch that does not have an MR
- Still change the MR checkbox to false when a user is on a branch that
  already has an MR
- Hide MR option when on a branch that already has an MR and committing
  to current branch
- Don't default to true when committing directly to master
2019-06-06 00:12:21 -04:00
Denys Mishunov 0d7afb9561 Updated heading for default state in Web IDE
Resolves https://gitlab.com/gitlab-org/gitlab-ce/issues/60107
2019-05-29 12:13:27 +00:00
Paul Slaughter 878e69299b
Rename vue_component_helper to text_helper
**Why?**
This file only contains a few text based helper functions.
It has nothing to do with Vue or Vue components.
2019-05-16 06:40:18 -05:00
Denys Mishunov 166c3ea296 Stores 'binary' and 'rawPath' attr after upload
- When uploading a file, we need to flag binary files correspondingly
so that it gets propagated all the way to RepoEditor as it decides on
whether to show editor for this or that file or not (shouldHideEditor())

- rawPath needs to be propagate all the way to ContentViewer as well so
that uploaded images could be rendered as a base64 image right away
instead of raw base64 string
2019-04-18 00:16:46 +02:00
Phil Hughes 66699030ef Merge branch '57482-shortcut-to-create-merge-request-from-web-ide' into 'master'
Resolve "Shortcut to create merge request from Web IDE"

Closes #57482

See merge request gitlab-org/gitlab-ce!26792
2019-04-05 13:48:25 +00:00
Paul Slaughter c1a097e1ce
Refactor new_dropdown/index to receive isOpen prop
**Why?**

Previously it managed this as an internal data property, but there
was extra complexity involved because the component doesn't have
all the information it needs (i.e. the `mouseOver` prop).

This is a good opportunity to colocate the data prop with the component
that has the information to change it (i.e. `file_row`) and let
`new_dropdown/index` receive this value as a prop.
2019-04-04 15:35:45 -05:00
Sam Bigelow 2571856fc5 Shortcut to create MR in web IDE
Before the user had to choose between committing to a new branch,
committing to a new branch AND creating an MR, or committing to the
current branch regardless of whether or not it already has an MR.

This commit separates the creation of an MR from whether or not they
commit to an existing or new branch
2019-04-04 12:08:35 -04:00
Paul Slaughter bd1122ee2f
Fix vue render error for IDE status bar
**What?**

A Vue warning that `ide_status_bar` sent a `Boolean` to a `String`
property (`img-src).

**What was the fix?**

Previously, `latestPipeline` could be one of the following values:

|          |        |
|----------|--------|
| `null`   | The pipeline hasn't loaded yet |
| `false`  | The pipeline has loaded, but nothing was returned. |
| `Object` | The piepline has loaded. |

Giving a semantic meaning to different falsey values hurts
maintainability. This commit fixes the above problem by removing the
`false` value and introducing a `hasLoadedPipeline` state property.
2019-04-04 10:00:44 -05:00
Tim Zallmann 4f0b2079de Upgraded Vue to 2.6.8
Upgrade to latest Version
2019-03-27 21:33:20 +00:00
Natalia Tepluhina a72241f4a9 Fixed commit logic to pick a branch
- fixed getter spec with correct getter name
2019-03-25 09:16:41 +00:00
Denys Mishunov 1a2bdb4366 Implemented trimming for item's name in Web IDE
Resolves https://gitlab.com/gitlab-org/gitlab-ce/issues/57540
2019-03-18 13:59:16 +01:00
Natalia Tepluhina d9ba40aa04 Fixed mutation for root
- fixed test spec
- added warning only if file is deleted
2019-03-04 11:39:55 +00:00
Sam Bigelow b82b1667c4 Dont show file template options for new directory 2019-02-13 08:57:34 -05:00
Phil Hughes 6e5461d67f
Added fuzzy file finder to merge requests
Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/53304
2019-02-05 11:29:49 +00:00
Jose 2375f7ff68 Resolve "Add Avatar from author of the last commit to WebIDE status bar" 2019-01-31 08:22:29 +00:00
Phil Hughes 5b8c806bee
Changed failing karma spec 2019-01-07 10:29:26 +00:00
Takuya Noguchi e902f462c2 Eliminate duplicated words
Signed-off-by: Takuya Noguchi <takninnovationresearch@gmail.com>
2018-11-22 01:01:23 +09:00
Jacques Erasmus d1fb29e573 Remove base64 encoding from files that contain plain text 2018-10-22 08:28:36 +00:00
Mike Greiling f666026d71
Prettify all spec files 2018-10-17 11:18:17 -05:00
Johann Hubert Sonntagbauer 6f5723a169 enable jasmine/new-line-before-expect 2018-10-17 06:57:29 +02:00
Phil Hughes 33c4c5b8f3
Added file tree to merge request diffs
This file tree displays all the diff files in a tree like format
Each file is taken and converted into a tree with folders
Each folder can be toggled open & closed
Clicking a file will scroll to the diff file & highlight with a glow affect

Searching the tree list will search only files & return a list of the
files without any folders

Each file row contains an icon to show changed, new file or deleted
Each row will also contain the added & removed lines count

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/14249
2018-10-03 10:05:43 +01:00
Paul Slaughter adbf6149cf Keep IDE RightPane views alive
**Why?**
- This is needed for the Web Terminal feature.
  https://gitlab.com/gitlab-org/gitlab-ee/issues/5426

**Notes:**
- Introduces a `pane` Vuex module.
- Some views should not be kept alive (i.e. job details).
  This is why a `keepAlive` flag was introduced for views.
2018-09-28 15:03:39 -05:00
Clement Ho 2a6cd526ac Add gitlab-ui skeleton loading 2018-09-25 20:03:40 +00:00
Phil Hughes b328218a71
Updated specs to account for removed buttons 2018-09-21 06:51:23 +01:00
Phil Hughes 163ec966c1
Decouple file row from IDE
This makes the file row component re-usable ouside of the Web IDE

Pre-request for https://gitlab.com/gitlab-org/gitlab-ce/issues/14249
2018-09-17 12:17:00 +01:00
Phil Hughes 9badf9e723
fixed `list_item_spec.js` 2018-09-07 11:28:03 +01:00
Phil Hughes 1f808ffe9e
update components to match designs in commit section 2018-09-07 11:28:01 +01:00
Phil Hughes 21ed2da067
fixed double scroll
improved variable & prop names
2018-09-07 08:24:42 +01:00
Phil Hughes 3f6500383f
fixed some bugs around with the template dropdowns 2018-09-07 08:24:42 +01:00
Phil Hughes 5b84c2fbc2
added component specs 2018-09-07 08:24:01 +01:00
Phil Hughes 27bce7ad2c
Fixed IDE file row jumping into view on hover
Closes #50751
2018-08-31 10:27:44 +01:00
Phil Hughes 3a283fa861
Enabled multiple uploads in the Web IDE
Closes #50405
2018-08-29 16:05:30 +01:00
Filipa Lacerda 632d3a9412 Merge branch 'ide-header-buttons-tooltip' into 'master'
Added tooltips to tree list header buttons in Web IDE

Closes #50141

See merge request gitlab-org/gitlab-ce!21138
2018-08-13 08:58:03 +00:00
Phil Hughes dcec090736
added spec 2018-08-13 08:40:15 +01:00
Phil Hughes f3d37980ce
fixed karma spec 2018-08-10 16:50:49 +01:00
Paul Slaughter 0d6e50d542 Create Web IDE MR and branch picker 2018-08-07 15:15:56 +00:00
Phil Hughes 7b4b9e1cc4
Web IDE & CodeSandbox
This enables JavaScripts projects to have live previews straight in the
browser without requiring any local configuration. This uses the
CodeSandbox package `sandpack` to compile it all inside of an iframe.

This feature is off by default and can be toggled on in the admin
settings. Only projects with a `package.json` and a `main` key are
supported.

Updates happen in real-time with hot-reloading. We just watch for
changes to files and then send them to `sandpack` to allow it to reload
the iframe. The iframe includes a very simple navigation bar, the text
bar is `readonly` to stop users navigating away from the preview and
the back and forward buttons just pop/splice the navigation stack
which is tracked by a listener on `sandpack`

There is a button inside the iframe which allows the user to open the
projects inside of CodeSandbox. This button is only visible on
**public** projects. On private or internal projects this button
get hidden to protect private code being leaked into an external
public URL.

Closes #47268
2018-08-07 14:45:55 +01:00
Paul Slaughter db739548fe Web IDE context header redesign 2018-08-07 13:19:13 +00:00
Filipa Lacerda b901df220c Merge branch 'ide-rename-files' into 'master'
Enable renaming files & folders in the Web IDE

Closes #44845

See merge request gitlab-org/gitlab-ce!20835
2018-08-03 10:00:48 +00:00
Phil Hughes 9e5bc59968
Fixed Web IDE row dropdowns scrolling list incorrectly
Closes #49892
2018-08-02 13:47:23 +01:00
Phil Hughes 3cbc2ea114
fixed karma 2018-07-31 10:33:44 +01:00
Filipa Lacerda 02e35a0d26 Merge branch 'ide-warn-staged-files' into 'master'
Warn in IDE when user navigates away with staged changes

See merge request gitlab-org/gitlab-ce!20857
2018-07-31 07:54:27 +00:00
Phil Hughes fd3ef2eb88
karma fixes 2018-07-30 17:35:56 +01:00
Phil Hughes 377afd65d1
Enable renaming files & folders in the Web IDE
Closes #44845
2018-07-30 11:45:14 +01:00
Felipe Artur 13ea4b387d Merge remote-tracking branch 'dev/master' 2018-07-26 18:30:50 -03:00
Felipe Artur Cardozo 9852304bef Merge branch 'security-ide-branch-name-xss' into 'master'
[master] Fixed XSS in branch name in Web IDE

See merge request gitlab/gitlabhq!2431
2018-07-26 21:16:24 +00:00
Phil Hughes cded268ca1 Enable deleting files in the Web IDE 2018-07-26 14:56:56 +00:00
Phil Hughes 4154477ca7
Warn in IDE when user navigates away with staged changes 2018-07-26 14:50:06 +01:00
Annabel Dunstone Gray 0deb8547af
Replace label-light with label-bold. Because it's bold, not light 2018-07-19 17:11:31 -05:00
Lukas Eipert 4ff134dfd4 Proper icon validator 2018-07-18 16:56:19 +00:00