Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion css/cloudinary.css

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions css/src/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,6 @@ $color-notification-success: #20b832;

/** Sizes */
$content-width: 870px;
$size-small: 783px;
$size-medium: 960px;
$size-large: 1200px;
147 changes: 59 additions & 88 deletions css/src/components/_ui.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@
.cld {

&-syncing {
background-image: url("./loading.svg");
background-repeat: no-repeat;
background-position: center center;
background: url("./loading.svg") no-repeat center center;
width: 30px;
height: 20px;
margin-left: 12px;
Expand All @@ -29,7 +27,14 @@
right: 0;
padding: 0;
color: #555d66;
margin-left: 160px;

@media only screen and (min-width: $size-small) {
margin-left: 36px;
}

@media only screen and (min-width: $size-medium) {
margin-left: 160px;
}

.cld-notice-box.is-success{
border: 0;
Expand Down Expand Up @@ -66,7 +71,7 @@
margin-right: 20px;
margin-bottom: 12px;
.cld-notice {
padding: 1rem 1.2rem 0.75rem 1.2rem;
padding: 1rem 2.2rem 0.75rem 1.2rem;

img.cld-ui-icon {
height: 100%;
Expand All @@ -81,12 +86,12 @@
padding-left: 38px;
}


&.is-success,
&.is-updated,
&.is-created {
background-color: #ebf5ec;
border-left: 4px solid #42ad4f;

.dashicons{
color: $color-success;
}
Expand Down Expand Up @@ -138,18 +143,6 @@
}

&-ui {
&-settings {

/* Small devices */
@media only screen and (max-width: 992px) {
margin: 0 10px 0 -10px;
}

@media only screen and (max-width: 782px) {
margin: 0 -1px 0 -10px;
}

}

&-collapse {
align-self: center;
Expand Down Expand Up @@ -181,10 +174,18 @@

.cld-column {
padding: 0 1.75em;
float: left;
width: 100%;
box-sizing: border-box;

/* Small devices */
@media only screen and (max-width: 782px) {
width: 100% !important;
@media only screen and (min-width: $size-small) {
&.column-45 {
width: 45%;
}

&.column-55 {
width: 55%;
}
}
}

Expand All @@ -193,25 +194,13 @@
clear: both;
display: table;
}

@media only screen {

.cld-column {
float: left;
width: 100%;
box-sizing: border-box;
}
}


}
}

&-image,
&-video {

&-preview {

background-color: rgba(216, 216, 216, 0.5);
padding: 7px;
border-radius: 5px;
Expand Down Expand Up @@ -252,6 +241,7 @@
padding: 0 1rem;
margin-left: -20px;
margin-top: -1em;
flex-wrap: wrap;

&-tab {
list-style: none;
Expand Down Expand Up @@ -295,7 +285,6 @@
}

&-input {

@include input;

.regular-text,
Expand Down Expand Up @@ -388,8 +377,6 @@
}
}
}


}
}

Expand All @@ -411,18 +398,26 @@

&-panel,
&-info-box,
&-panel-short {
&-panel-short,
&-submit,
&-switch-cloud {
background-color: #fff;
border: 1px solid $color-light-grey;
padding: 2rem 1.75rem;
margin-top: 1rem;
margin-right: 1rem;
width: $content-width;
max-width: $content-width;
}

/* Medium devices until large */
@media only screen and (min-width: 993px) {
max-width: 900px;
}
&-submit,
&-switch-cloud {
border-top: 0;
padding: 1.2rem 1.75rem;
}

&-panel,
&-info-box,
&-panel-short {
margin-top: 1rem;
padding: 2rem 1.75rem;

&-inner {
padding: 1.3rem;
Expand Down Expand Up @@ -451,26 +446,12 @@

&-heading {
display: flex;
background-color: #fff;
border: 1px solid $color-light-grey;
border-bottom: 0;
padding: 0.4rem 1.75rem 0.2rem;
width: $content-width;
margin-top: 1rem;

img {
margin-right: 0.6rem;
}

/* Small devices */
@media only screen and (max-width: 960px) {
width: auto;
}

/* Medium devices until large */
@media only screen and (min-width: 961px) and (max-width: 1200px) {
width: 85%;
}
}

ul {
Expand Down Expand Up @@ -527,7 +508,7 @@
font-weight: 400;
}

@media only screen and (min-width: 783px) {
@media only screen and (min-width: $size-small) {
display: flex;
flex-wrap: nowrap;
font-size: 1em;
Expand All @@ -543,13 +524,14 @@
}
}

@media only screen and (min-width: 1200px) {
@media only screen and (min-width: $size-large) {
font-size: 1.2em;
}
}

.img-connection-string {
max-width: 607px;
width: 100%;
}

.connection-string {
Expand Down Expand Up @@ -619,8 +601,12 @@
}

&-info-box {

display: flex;
flex-direction: column;

@media only screen and (min-width: $size-small) {
flex-direction: row;
}

img,
a.button {
Expand All @@ -638,42 +624,27 @@
display: inline-block;
}

&-submit,
&-switch-cloud {

&.cld-ui-wrap {
background-color: #fff;
border: 1px solid $color-light-grey;
border-top: 0;
padding: 1.2rem 1.75rem;
width: $content-width;

/* Small devices */
@media only screen and (max-width: 960px) {
width: auto;
}

/* Medium devices until large */
@media only screen and (min-width: 961px) and (max-width: 1200px) {
width: 85%;
}
}
}

&-gallery-settings {
width: 100%;
display: flex;
flex-wrap: wrap;
padding: 1rem 0;
margin-left: -1rem;
margin-right: -1rem;
box-sizing: border-box;

@media only screen and (min-width: $size-medium) {
margin-left: -1rem;
margin-right: -1rem;
}

&__column {
width: 50%;
padding-left: 1rem;
padding-right: 1rem;
box-sizing: border-box;
width: 100%;

@media only screen and (min-width: $size-medium) {
padding-left: 1rem;
padding-right: 1rem;
width: 50%;
}
}
}
}
Expand Down
1 change: 1 addition & 0 deletions php/class-connect.php
Original file line number Diff line number Diff line change
Expand Up @@ -498,6 +498,7 @@ public function setup() {
'target' => '_self',
'attributes' => array(
'class' => array(
'button',
'button-secondary',
),
'link_tag' => array(
Expand Down
2 changes: 1 addition & 1 deletion php/class-deactivation.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public function get_reasons() {
*/
public function markup() {
?>
<a href="#TB_inline?&width=520&height=390&inlineId=cloudinary-deactivation" class="thickbox" id="cld-deactivation-link" title="<?php esc_attr_e( 'Tell us how to improve!', 'cloudinary' ); ?>"><?php esc_html_e( 'Deactivation feedback', 'cloudinary' ); ?>></a>
<a href="#TB_inline?&width=520&height=390&inlineId=cloudinary-deactivation" class="thickbox" id="cld-deactivation-link" title="<?php esc_attr_e( 'Tell us how to improve!', 'cloudinary' ); ?>" style="display: none;"><?php esc_html_e( 'Deactivation feedback', 'cloudinary' ); ?>></a>
<div id="cloudinary-deactivation" style="display: none;">
<div class="cloudinary-deactivation">
<div class="modal-body">
Expand Down
4 changes: 4 additions & 0 deletions php/ui/component/class-column.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ protected function wrap( $struct ) {
$struct['attributes']['style'] = 'width:' . $this->setting->get_param( 'width' ) . ';';
}

if ( $this->setting->has_param( 'class' ) ) {
$struct['attributes']['class'] = array_merge( $struct['attributes']['class'], $this->setting->get_param( 'class' ) );
}

return $struct;
}

Expand Down
8 changes: 6 additions & 2 deletions ui-definitions/settings-image.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@
'type' => 'row',
array(
'type' => 'column',
'width' => '45%',
'class' => array(
'column-45',
),
array(
'type' => 'group',
array(
Expand Down Expand Up @@ -154,7 +156,9 @@
),
array(
'type' => 'column',
'width' => '55%',
'class' => array(
'column-55',
),
array(
'type' => 'image_preview',
'title' => __( 'Image preview', 'cloudinary' ),
Expand Down
8 changes: 6 additions & 2 deletions ui-definitions/settings-video.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@
'type' => 'row',
array(
'type' => 'column',
'width' => '45%',
'class' => array(
'column-45',
),
array(
'type' => 'group',
array(
Expand Down Expand Up @@ -173,7 +175,9 @@
),
array(
'type' => 'column',
'width' => '55%',
'class' => array(
'column-55',
),
array(
'type' => 'video_preview',
'title' => __( 'Video preview', 'cloudinary' ),
Expand Down