@@ -15,10 +15,6 @@ import StepWrapper from 'calypso/signup/step-wrapper';
15
15
import { isUserLoggedIn , getCurrentUser } from 'calypso/state/current-user/selectors' ;
16
16
import { getAvailableProductsList } from 'calypso/state/products-list/selectors' ;
17
17
import { submitSignupStep } from 'calypso/state/signup/progress/actions' ;
18
- import SiteOrDomainChoice from './choice' ;
19
- import DomainImage from './domain-image' ;
20
- import ExistingSiteImage from './existing-site-image' ;
21
- import NewSiteImage from './new-site-image' ;
22
18
23
19
import './style.scss' ;
24
20
@@ -58,7 +54,7 @@ class SiteOrDomain extends Component {
58
54
}
59
55
60
56
getChoices ( ) {
61
- const { translate, isReskinned , isLoggedIn, siteCount } = this . props ;
57
+ const { translate, isLoggedIn, siteCount } = this . props ;
62
58
63
59
const domainName = this . getDomainName ( ) ;
64
60
let buyADomainTitle = translate ( 'Just buy a domain' , 'Just buy domains' , {
@@ -72,22 +68,40 @@ class SiteOrDomain extends Component {
72
68
const choices = [ ] ;
73
69
74
70
const buyADomainDescription = translate ( 'Add a site later.' ) ;
75
- if ( isReskinned ) {
76
- choices . push ( {
77
- key : 'domain' ,
78
- title : buyADomainTitle ,
79
- description : buyADomainDescription ,
80
- icon : null ,
81
- titleIcon : globe ,
82
- value : 'domain' ,
83
- actionText : < Gridicon icon = "chevron-right" size = { 18 } /> ,
84
- allItemClickable : true ,
85
- } ) ;
71
+ choices . push ( {
72
+ key : 'domain' ,
73
+ title : buyADomainTitle ,
74
+ description : buyADomainDescription ,
75
+ icon : null ,
76
+ titleIcon : globe ,
77
+ value : 'domain' ,
78
+ actionText : < Gridicon icon = "chevron-right" size = { 18 } /> ,
79
+ allItemClickable : true ,
80
+ } ) ;
81
+ choices . push ( {
82
+ key : 'page' ,
83
+ title : translate ( 'New site' ) ,
84
+ description : translate (
85
+ 'Customize and launch your site.{{br/}}{{strong}}Free domain for the first year on annual plans.{{/strong}}' ,
86
+ {
87
+ components : {
88
+ strong : < strong /> ,
89
+ br : < br /> ,
90
+ } ,
91
+ }
92
+ ) ,
93
+ icon : null ,
94
+ titleIcon : addCard ,
95
+ value : 'page' ,
96
+ actionText : < Gridicon icon = "chevron-right" size = { 18 } /> ,
97
+ allItemClickable : true ,
98
+ } ) ;
99
+ if ( isLoggedIn && siteCount > 0 ) {
86
100
choices . push ( {
87
- key : 'page ' ,
88
- title : translate ( 'New site' ) ,
101
+ key : 'existing-site ' ,
102
+ title : translate ( 'Existing WordPress.com site' ) ,
89
103
description : translate (
90
- 'Customize and launch your site.{{br/}}{{strong}}Free domain for the first year on annual plans.{{/strong}}' ,
104
+ 'Use the domain with a site you already started .{{br/}}{{strong}}Free domain for the first year on annual plans.{{/strong}}' ,
91
105
{
92
106
components : {
93
107
strong : < strong /> ,
@@ -96,86 +110,24 @@ class SiteOrDomain extends Component {
96
110
}
97
111
) ,
98
112
icon : null ,
99
- titleIcon : addCard ,
100
- value : 'page ' ,
113
+ titleIcon : layout ,
114
+ value : 'existing-site ' ,
101
115
actionText : < Gridicon icon = "chevron-right" size = { 18 } /> ,
102
116
allItemClickable : true ,
103
117
} ) ;
104
- if ( isLoggedIn && siteCount > 0 ) {
105
- choices . push ( {
106
- key : 'existing-site' ,
107
- title : translate ( 'Existing WordPress.com site' ) ,
108
- description : translate (
109
- 'Use the domain with a site you already started.{{br/}}{{strong}}Free domain for the first year on annual plans.{{/strong}}' ,
110
- {
111
- components : {
112
- strong : < strong /> ,
113
- br : < br /> ,
114
- } ,
115
- }
116
- ) ,
117
- icon : null ,
118
- titleIcon : layout ,
119
- value : 'existing-site' ,
120
- actionText : < Gridicon icon = "chevron-right" size = { 18 } /> ,
121
- allItemClickable : true ,
122
- } ) ;
123
- }
124
- } else {
125
- choices . push ( {
126
- type : 'page' ,
127
- label : translate ( 'New site' ) ,
128
- image : < NewSiteImage /> ,
129
- description : translate (
130
- 'Choose a theme, customize, and launch your site. A free domain for one year is included with all annual plans.'
131
- ) ,
132
- } ) ;
133
- if ( isLoggedIn && siteCount > 0 ) {
134
- choices . push ( {
135
- type : 'existing-site' ,
136
- label : translate ( 'Existing WordPress.com site' ) ,
137
- image : < ExistingSiteImage /> ,
138
- description : translate (
139
- 'Use with a site you already started. A free domain for one year is included with all annual plans.'
140
- ) ,
141
- } ) ;
142
- }
143
- choices . push ( {
144
- type : 'domain' ,
145
- label : buyADomainTitle ,
146
- image : < DomainImage /> ,
147
- description : buyADomainDescription ,
148
- } ) ;
149
118
}
150
119
151
120
return choices ;
152
121
}
153
122
154
123
renderChoices ( ) {
155
- const { isReskinned } = this . props ;
156
-
157
124
return (
158
125
< div className = "site-or-domain__choices" >
159
- { isReskinned ? (
160
- < >
161
- < SelectItems
162
- items = { this . getChoices ( ) }
163
- onSelect = { this . handleClickChoice }
164
- preventWidows = { preventWidows }
165
- />
166
- </ >
167
- ) : (
168
- < >
169
- { this . getChoices ( ) . map ( ( choice , index ) => (
170
- < SiteOrDomainChoice
171
- choice = { choice }
172
- handleClickChoice = { this . handleClickChoice }
173
- isPlaceholder = { ! this . props . productsLoaded }
174
- key = { `site-or-domain-choice-${ index } ` }
175
- />
176
- ) ) }
177
- </ >
178
- ) }
126
+ < SelectItems
127
+ items = { this . getChoices ( ) }
128
+ onSelect = { this . handleClickChoice }
129
+ preventWidows = { preventWidows }
130
+ />
179
131
</ div >
180
132
) ;
181
133
}
@@ -249,7 +201,7 @@ class SiteOrDomain extends Component {
249
201
} ;
250
202
251
203
render ( ) {
252
- const { translate, productsLoaded, isReskinned } = this . props ;
204
+ const { translate, productsLoaded } = this . props ;
253
205
const domainName = this . getDomainName ( ) ;
254
206
255
207
if ( productsLoaded && ! domainName ) {
@@ -277,10 +229,8 @@ class SiteOrDomain extends Component {
277
229
const additionalProps = { } ;
278
230
let headerText = this . props . getHeaderText ( this . getDomainCart ( ) ) ;
279
231
280
- if ( isReskinned ) {
281
- additionalProps . isHorizontalLayout = false ;
282
- additionalProps . align = 'center' ;
283
- }
232
+ additionalProps . isHorizontalLayout = false ;
233
+ additionalProps . align = 'center' ;
284
234
285
235
if ( this . isLeanDomainSearch ( ) ) {
286
236
additionalProps . className = 'lean-domain-search' ;
0 commit comments