Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Create and publish dialog #2222

Merged
merged 78 commits into from
Oct 4, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
ad2205e
Component to choose a repository owner and name
smashwilson Jul 22, 2019
9e76acf
GraphQL builder fields
smashwilson Jul 22, 2019
598d601
Directory creation component
smashwilson Jul 23, 2019
1d8742a
Control DirectorySelect enablement
smashwilson Jul 23, 2019
edf622b
Common "advanced" source remote configuration controls
smashwilson Jul 23, 2019
2a4929e
wip
smashwilson Jul 24, 2019
48588ea
Config settings to make source remote name and fetch protocol sticky
smashwilson Jul 24, 2019
f192194
Rename props in RepositoryHomeSelectionView
smashwilson Jul 24, 2019
74ce7a3
CreateDialogView for the create/publish dialog with GraphQL results
smashwilson Jul 24, 2019
19daeaa
Refactor stateful logic into CreateDialogController
smashwilson Jul 24, 2019
4e92525
Builder for top-level `viewer` object
smashwilson Jul 25, 2019
c300eed
Propagate propTypes up the CreateDialog stack
smashwilson Jul 25, 2019
0e7080a
Flesh out the CreateDialogContainer
smashwilson Jul 25, 2019
a4e90f8
GraphQL builder fields for createRepository mutation
smashwilson Jul 26, 2019
3a4946e
CreateDialog and create and publish action methods
smashwilson Jul 26, 2019
09669fc
Pass currentWindow to RootController
smashwilson Jul 26, 2019
3d21f6c
Allow RelayNetworkLayerManager to be called without a token
smashwilson Jul 27, 2019
a4737a7
isPublishable() -> true for present repositories
smashwilson Jul 27, 2019
67f2626
`github:create-repository` and `github:publish-repository` commands
smashwilson Jul 27, 2019
1beab81
Accept a source remote name when cloning a repository
smashwilson Jul 27, 2019
78e7c9d
Pass currentWindow and loginModel to DialogsController
smashwilson Jul 29, 2019
e4ecedb
Register create and publish dialogs in DialogsController
smashwilson Jul 29, 2019
5fad68a
Render BareRepositoryHomeSelectionView directly while loading
smashwilson Jul 29, 2019
5809a6c
Accept AutoFocus in RepositoryHomeSelectionView
smashwilson Jul 29, 2019
478d62e
Employ AutoFocus in CreateDialogView
smashwilson Jul 29, 2019
d1d62f0
Modify DialogsController tests to add missing props
smashwilson Jul 29, 2019
1f83c42
Lift AutoFocus up to CreateDialog
smashwilson Jul 29, 2019
fabc47b
Use the Endpoint's login account to get the token
smashwilson Jul 29, 2019
77e4fb2
The GraphQL user field is "viewer"
smashwilson Jul 29, 2019
ca21182
Relay fragmentContainer composition does not work that way
smashwilson Jul 29, 2019
68e095a
:gear: relay :gear:
smashwilson Jul 29, 2019
c21a044
Use github-Create- instead of github-Publish-
smashwilson Jul 29, 2019
dfa7647
Tinker with react-select option markup
smashwilson Jul 29, 2019
6b63e50
CSS
smashwilson Jul 29, 2019
b6c806d
Re-render controller when request state changes
smashwilson Jul 29, 2019
26586b5
Always pass a real ID to ownerID
smashwilson Jul 30, 2019
19e9b50
Autopage the organization collection
smashwilson Jul 30, 2019
9cfbfea
Relay containers understand explicitly null props
smashwilson Jul 30, 2019
f00c42c
Use the exported organization page size
smashwilson Jul 30, 2019
0f13adc
Retain and render with the last Relay props to avoid loading flicker
smashwilson Jul 30, 2019
e2dea4b
Style radio and details buttons when focused
smashwilson Jul 30, 2019
e726af0
Trigger autofocus when CreateDialogView mounts
smashwilson Jul 30, 2019
14540f5
Enable name editor while organizations are loading
smashwilson Jul 30, 2019
9df9a18
TabGroup to assign form elements distinct, increasing tabIndex
smashwilson Jul 31, 2019
f681590
Use TabGroup through CreateDialog components
smashwilson Jul 31, 2019
8e713cc
State typo
smashwilson Jul 31, 2019
699d87c
Use TabGroup in other dialogs
smashwilson Jul 31, 2019
ecfd0a8
Child TabGroups and resetting to handle being passed among components
smashwilson Jul 31, 2019
557d7b3
Put tabGroup and autoFocus in CreateDialogView
smashwilson Jul 31, 2019
7dec227
Reset tabGroups at the start of each render
smashwilson Jul 31, 2019
b088d80
Select non-bare children
smashwilson Jul 31, 2019
669975a
CSS for react-select
smashwilson Aug 4, 2019
05b9596
Wait until Repository loads to register publish command
smashwilson Aug 4, 2019
d19c152
Manage focus manually with Tabbable components
smashwilson Aug 5, 2019
5baa35c
External refElements in AtomTextEditor
smashwilson Oct 1, 2019
0e4cc81
Tabbable Select lists
smashwilson Oct 1, 2019
f6f5763
Use the new TabGroup scheme in CreateDialogView
smashwilson Oct 1, 2019
c45485f
Bind tab for good measure
smashwilson Oct 1, 2019
5888002
Use TabGroup for other dialogs
smashwilson Oct 1, 2019
7f6462e
Proxy keydown events to TabbableSelect
smashwilson Oct 2, 2019
3ebdfbd
Standardize `github:selectbox-` events
smashwilson Oct 2, 2019
f675f9a
Walk focus lists to skip disabled or hidden elements when tabbing
smashwilson Oct 2, 2019
57608b6
Tabbable tests
smashwilson Oct 2, 2019
a1c55af
CloneDialog tests
smashwilson Oct 2, 2019
0f20ab3
InitDialog tests
smashwilson Oct 2, 2019
c46f68a
RemoteConfigurationView tests
smashwilson Oct 2, 2019
190d4a9
Clean up the atomEnv
smashwilson Oct 2, 2019
ed8812c
Disable accept button while the query is running
smashwilson Oct 3, 2019
a5e9e12
CreateDialogController tests
smashwilson Oct 3, 2019
645ed10
GitHub package test coverage
smashwilson Oct 3, 2019
584c105
RootController publish dialog tests
smashwilson Oct 3, 2019
d0b04d7
TabGroup tests
smashwilson Oct 3, 2019
7aacfa4
RepositoryHomeSelectionView tests
smashwilson Oct 3, 2019
c85a910
:white_check_mark: remaining tests :fingers_crossed:
smashwilson Oct 3, 2019
960a66f
Enable the accept button after the user loads
smashwilson Oct 4, 2019
fcbbb7e
Stop focus event propagation
smashwilson Oct 4, 2019
d34a2be
Pass fake event to focus callbacks
smashwilson Oct 4, 2019
9c0d6fb
Avoid variable name shadowing
smashwilson Oct 4, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 14 additions & 11 deletions keymaps/git.cson
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@
'esc': 'tool-panel:unfocus'

'.github-Dialog':
'tab': 'core:focus-next'
'shift-tab': 'core:focus-previous'

'.github-Dialog input':
Expand All @@ -120,18 +121,20 @@
'.github-CoAuthorForm input':
'enter': 'core:confirm'

'body .github-TabbableWrapper':
'down': 'github:selectbox-down'
'up': 'github:selectbox-up'
'enter': 'github:selectbox-enter'
'tab': 'github:selectbox-tab'
'backspace': 'github:selectbox-backspace'
'pageup': 'github:selectbox-pageup'
'pagedown': 'github:selectbox-pagedown'
'end': 'github:selectbox-end'
'home': 'github:selectbox-home'
'delete': 'github:selectbox-delete'
'escape': 'github:selectbox-escape'

'body .github-CommitView-coAuthorEditor':
'enter': 'github:co-author:enter'
'down': 'github:co-author:down'
'up': 'github:co-author:up'
'tab': 'github:co-author:tab'
'backspace': 'github:co-author:backspace'
'escape': 'github:co-author:escape'
'pageup': 'github:co-author:pageup'
'pagedown': 'github:co-author:pagedown'
'home': 'github:co-author:home'
'end': 'github:co-author:end'
'delete': 'github:co-author:delete'
'shift-backspace': 'github:co-author-exclude'

'.platform-darwin .github-Reviews':
Expand Down
25 changes: 19 additions & 6 deletions lib/atom/atom-text-editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export default class AtomTextEditor extends React.Component {
tabIndex: PropTypes.number,

refModel: RefHolderPropType,
refElement: RefHolderPropType,

children: PropTypes.node,
}
Expand All @@ -62,7 +63,7 @@ export default class AtomTextEditor extends React.Component {
this.subs = new CompositeDisposable();

this.refParent = new RefHolder();
this.refElement = new RefHolder();
this.refElement = null;
this.refModel = null;
}

Expand Down Expand Up @@ -91,7 +92,7 @@ export default class AtomTextEditor extends React.Component {
}
element.appendChild(editor.getElement());
this.getRefModel().setter(editor);
this.refElement.setter(editor.getElement());
this.getRefElement().setter(editor.getElement());

this.subs.add(
editor.onDidChangeCursorPosition(this.props.didChangeCursorPosition),
Expand Down Expand Up @@ -136,20 +137,20 @@ export default class AtomTextEditor extends React.Component {
observeEmptiness = () => {
this.getRefModel().map(editor => {
if (editor.isEmpty() && this.props.hideEmptiness) {
this.refElement.map(element => element.classList.add(EMPTY_CLASS));
this.getRefElement().map(element => element.classList.add(EMPTY_CLASS));
} else {
this.refElement.map(element => element.classList.remove(EMPTY_CLASS));
this.getRefElement().map(element => element.classList.remove(EMPTY_CLASS));
}
return null;
});
}

contains(element) {
return this.refElement.map(e => e.contains(element)).getOr(false);
return this.getRefElement().map(e => e.contains(element)).getOr(false);
}

focus() {
this.refElement.map(e => e.focus());
this.getRefElement().map(e => e.focus());
}

getRefModel() {
Expand All @@ -164,6 +165,18 @@ export default class AtomTextEditor extends React.Component {
return this.refModel;
}

getRefElement() {
if (this.props.refElement) {
return this.props.refElement;
}

if (!this.refElement) {
this.refElement = new RefHolder();
}

return this.refElement;
}

getModel() {
return this.getRefModel().getOr(undefined);
}
Expand Down
283 changes: 283 additions & 0 deletions lib/containers/__generated__/createDialogContainerQuery.graphql.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading