Просмотр исходного кода

ctools modal css + description white on black

Signed-off-by: bachy <git@g-u-i.net>
bachy 13 лет назад
Родитель
Сommit
746109f079
5 измененных файлов с 136 добавлено и 187 удалено
  1. 0 0
      css/guibik.css
  2. BIN
      images/popup.png
  3. 27 185
      images/popup.svg
  4. 25 2
      less/guibik.less
  5. 84 0
      template.php

Разница между файлами не показана из-за своего большого размера
+ 0 - 0
css/guibik.css


BIN
images/popup.png


+ 27 - 185
images/popup.svg

@@ -1,185 +1,27 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-<svg
-   xmlns:dc="http://purl.org/dc/elements/1.1/"
-   xmlns:cc="http://creativecommons.org/ns#"
-   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-   xmlns:svg="http://www.w3.org/2000/svg"
-   xmlns="http://www.w3.org/2000/svg"
-   xmlns:xlink="http://www.w3.org/1999/xlink"
-   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
-   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
-   width="260"
-   height="480"
-   id="svg2"
-   sodipodi:version="0.32"
-   inkscape:version="0.46"
-   version="1.0"
-   inkscape:export-filename="/home/devseed/d6/sites/all/themes/rubik/images/popup.png"
-   inkscape:export-xdpi="90"
-   inkscape:export-ydpi="90"
-   sodipodi:docname="popup.svg"
-   inkscape:output_extension="org.inkscape.output.svg.inkscape">
-  <defs
-     id="defs4">
-    <linearGradient
-       inkscape:collect="always"
-       id="linearGradient3265">
-      <stop
-         style="stop-color:#000000;stop-opacity:0.1254902"
-         offset="0"
-         id="stop3267" />
-      <stop
-         style="stop-color:#000000;stop-opacity:0;"
-         offset="1"
-         id="stop3269" />
-    </linearGradient>
-    <linearGradient
-       inkscape:collect="always"
-       id="linearGradient3215">
-      <stop
-         style="stop-color:#f8fffc;stop-opacity:1"
-         offset="0"
-         id="stop3217" />
-      <stop
-         style="stop-color:#f0f8f4;stop-opacity:1"
-         offset="1"
-         id="stop3219" />
-    </linearGradient>
-    <inkscape:perspective
-       sodipodi:type="inkscape:persp3d"
-       inkscape:vp_x="0 : 526.18109 : 1"
-       inkscape:vp_y="0 : 1000 : 0"
-       inkscape:vp_z="744.09448 : 526.18109 : 1"
-       inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
-       id="perspective10" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3265"
-       id="linearGradient3271"
-       x1="230.76921"
-       y1="470"
-       x2="240"
-       y2="470"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.5416667,0,0,0.6,130,188)" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3265"
-       id="linearGradient3275"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.5416667,0,0,0.6,-130,188)"
-       x1="230.76921"
-       y1="470"
-       x2="240"
-       y2="470" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3215"
-       id="linearGradient3283"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(1.0840336,0,0,1,-8.4033613e-2,-889)"
-       x1="239.92249"
-       y1="1339"
-       x2="239.92249"
-       y2="1359" />
-  </defs>
-  <sodipodi:namedview
-     id="base"
-     pagecolor="#ffffff"
-     bordercolor="#666666"
-     borderopacity="1.0"
-     gridtolerance="10000"
-     guidetolerance="10"
-     objecttolerance="10"
-     inkscape:pageopacity="0.0"
-     inkscape:pageshadow="2"
-     inkscape:zoom="14.551915"
-     inkscape:cx="13.515505"
-     inkscape:cy="13.816348"
-     inkscape:document-units="px"
-     inkscape:current-layer="layer1"
-     showgrid="false">
-    <inkscape:grid
-       type="xygrid"
-       id="grid3153"
-       visible="true"
-       enabled="true" />
-  </sodipodi:namedview>
-  <metadata
-     id="metadata7">
-    <rdf:RDF>
-      <cc:Work
-         rdf:about="">
-        <dc:format>image/svg+xml</dc:format>
-        <dc:type
-           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
-      </cc:Work>
-    </rdf:RDF>
-  </metadata>
-  <g
-     inkscape:label="Layer 1"
-     inkscape:groupmode="layer"
-     id="layer1">
-    <path
-       style="opacity:1;fill:#d8e4e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       d="M 0,0 L 0,470 L 260,470 L 260,0 L 259,0 L 259,469 L 1,469 L 1,0 L 0,0 z"
-       id="rect3157"
-       sodipodi:nodetypes="ccccccccc" />
-    <path
-       style="opacity:1;fill:#b8c8c0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       d="M 0,469 L 0,470 L 260,470 L 260,469 L 258.91666,469 L 1.0833334,469 L 0,469 z"
-       id="rect3163" />
-    <rect
-       y="470"
-       x="-130"
-       height="1.5"
-       width="130"
-       id="rect3273"
-       style="opacity:0.94999999999999996;fill:url(#linearGradient3275);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25000000000000000;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       transform="scale(-1,1)" />
-    <rect
-       style="opacity:0.94999999999999996;fill:url(#linearGradient3271);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25000000000000000;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       id="rect3263"
-       width="130"
-       height="1.5"
-       x="130"
-       y="470" />
-    <rect
-       style="opacity:1;fill:url(#linearGradient3283);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25000000000000000;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;color:#000000"
-       id="rect3155"
-       width="258"
-       height="469"
-       x="1"
-       y="0" />
-    <path
-       style="fill:#b8c8c0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       d="M 120.5,469 L 130,480 L 139.5,469"
-       id="path3159"
-       sodipodi:nodetypes="ccc" />
-    <path
-       sodipodi:nodetypes="ccc"
-       id="path3165"
-       d="M 122,469 L 130,478.5 L 138,469"
-       style="fill:#f0f8f4;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25000000000000000;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate" />
-    <path
-       style="fill:#f8fffc;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25;stroke-linecap:square;stroke-linejoin:round;stroke-miterlimit:0;stroke-dashoffset:0;stroke-opacity:1;marker:none;marker-start:none;marker-mid:none;marker-end:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       d="M 1,468 L 1,469 L 122,469 L 130,478.5 L 138,469 L 259,469 L 259,468 L 137,468 L 130,476.5 L 123,468 L 1,468 z"
-       id="rect3285"
-       sodipodi:nodetypes="ccccccccccc" />
-    <rect
-       style="opacity:1;fill:#f8fffc;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       id="rect3294"
-       width="1"
-       height="469"
-       x="258"
-       y="-7.7449158e-13" />
-    <rect
-       style="opacity:1;fill:#f8fffc;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.25;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:0;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
-       id="rect3296"
-       width="1"
-       height="469"
-       x="1"
-       y="-7.7449158e-13" />
-  </g>
-</svg>
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Generator: Adobe Illustrator 15.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0)  -->
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
+<svg version="1.1"
+	 id="svg2" inkscape:export-xdpi="90" inkscape:output_extension="org.inkscape.output.svg.inkscape" inkscape:export-ydpi="90" xmlns:svg="http://www.w3.org/2000/svg" sodipodi:version="0.32" sodipodi:docname="popup.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" inkscape:version="0.46" xmlns:cc="http://creativecommons.org/ns#" inkscape:export-filename="/home/devseed/d6/sites/all/themes/rubik/images/popup.png"
+	 xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="260px" height="480px"
+	 viewBox="0 0 260 480" enable-background="new 0 0 260 480" xml:space="preserve">
+<defs>
+	
+	
+		<inkscape:perspective  inkscape:vp_y="0 : 1000 : 0" inkscape:vp_z="744.09448 : 526.18109 : 1" inkscape:persp3d-origin="372.04724 : 350.78739 : 1" id="perspective10" inkscape:vp_x="0 : 526.18109 : 1" sodipodi:type="inkscape:persp3d">
+		</inkscape:perspective>
+</defs>
+<sodipodi:namedview  inkscape:pageopacity="0.0" inkscape:zoom="14.551915" inkscape:cx="13.515505" inkscape:cy="13.816348" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="false" id="base" pagecolor="#ffffff" bordercolor="#666666" borderopacity="1.0" gridtolerance="10000" guidetolerance="10" objecttolerance="10" inkscape:pageshadow="2">
+	<inkscape:grid  type="xygrid" visible="true" enabled="true" id="grid3153"></inkscape:grid>
+</sodipodi:namedview>
+<defs>
+	
+	
+		<inkscape:perspective  inkscape:vp_y="0 : 1000 : 0" inkscape:vp_z="744.09448 : 526.18109 : 1" inkscape:persp3d-origin="372.04724 : 350.78739 : 1" id="perspective10" inkscape:vp_x="0 : 526.18109 : 1" sodipodi:type="inkscape:persp3d">
+		</inkscape:perspective>
+</defs>
+<sodipodi:namedview  inkscape:pageopacity="0.0" inkscape:zoom="14.551915" inkscape:cx="13.515505" inkscape:cy="13.816348" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="false" id="base" pagecolor="#ffffff" bordercolor="#666666" borderopacity="1.0" gridtolerance="10000" guidetolerance="10" objecttolerance="10" inkscape:pageshadow="2">
+	<inkscape:grid  type="xygrid" visible="true" enabled="true" id="grid3153"></inkscape:grid>
+</sodipodi:namedview>
+<polygon opacity="0.7" fill="#1A1A1A" points="0,0 0,470.5 122,470.5 130,480 138,470.5 260,470.5 260,0 "/>
+</svg>

+ 25 - 2
less/guibik.less

@@ -83,8 +83,10 @@ select.form-select {
 
 
 /** popup description */
 /** popup description */
 .page-content .form-item .description {
 .page-content .form-item .description {
-  color:#0092D2;
+  color:#fff;
   border-top:1px solid #E0E0E0;
   border-top:1px solid #E0E0E0;
+/*	background: #1A1A1A url() no-repeat scroll top left;*/
+	background:url(../images/popup.png) 50% 100% no-repeat;
 	a{text-decoration: underline;}
 	a{text-decoration: underline;}
 }
 }
 
 
@@ -131,7 +133,7 @@ li{list-style: none inside url();}
   border:1px solid #BFBFBF;
   border:1px solid #BFBFBF;
   margin:0px 0px 10px;
   margin:0px 0px 10px;
   position:relative;
   position:relative;
-  }
+}
 
 
 .vertical-tabs .fieldset-content,
 .vertical-tabs .fieldset-content,
 .vertical-tabs fieldset.titled .fieldset-content {
 .vertical-tabs fieldset.titled .fieldset-content {
@@ -398,3 +400,24 @@ body.admin-vertical.admin-expanded #admin-menu-wrapper{border-left:1px solid #32
 
 
 }
 }
 
 
+
+#modalContent{
+		
+}
+
+#modalContent div.ctools-modal-content{
+	padding:5px;
+	-moz-border-radius: 10px;
+		-webkit-border-radius: 10px;
+		border-radius: 10px;
+		
+	border: 1 solid #999;
+	
+}
+#modalContent div.ctools-modal-content .modal-header,
+#modalContent div.ctools-modal-content .modal-header a,
+#modalContent div.ctools-modal-content .modal-header span{
+	background-color: transparent; color:#000!important;
+}
+
+

+ 84 - 0
template.php

@@ -123,3 +123,87 @@ function guibik_preprocess_html(&$vars){
 	
 	
 	
 	
 }
 }
+
+/**
+ * Implements theme_form_element().
+ */
+function OUT_guibik_form_element($variables) {
+  $element = &$variables['element'];
+  // This is also used in the installer, pre-database setup.
+  $t = get_t();
+	
+	dsm($element);
+
+  // This function is invoked as theme wrapper, but the rendered form element
+  // may not necessarily have been processed by form_builder().
+  $element += array(
+    '#title_display' => 'before',
+  );
+
+  // Add element #id for #type 'item'.
+  if (isset($element['#markup']) && !empty($element['#id'])) {
+    $attributes['id'] = $element['#id'];
+  }
+  // Add element's #type and #name as class to aid with JS/CSS selectors.
+	if(!isset($element["#attributes"]['class']))
+		$element["#attributes"]['class'] = array();
+		
+	$attributes['class'] = $element["#attributes"]['class'] + array('form-item');
+  if (!empty($element['#type'])) {
+    $attributes['class'][] = 'form-type-' . strtr($element['#type'], '_', '-');
+  }
+  if (!empty($element['#name'])) {
+    $attributes['class'][] = 'form-item-' . strtr($element['#name'], array(' ' => '-', '_' => '-', '[' => '-', ']' => ''));
+  }
+  // Add a class for disabled elements to facilitate cross-browser styling.
+  if (!empty($element['#attributes']['disabled'])) {
+    $attributes['class'][] = 'form-disabled';
+  }
+  $output = '<div' . drupal_attributes($attributes) . '>' . "\n";
+
+  // If #title is not set, we don't display any label or required marker.
+  if (!isset($element['#title'])) {
+    $element['#title_display'] = 'none';
+  }
+  $prefix = isset($element['#field_prefix']) ? '<span class="field-prefix">' . $element['#field_prefix'] . '</span> ' : '';
+  $suffix = isset($element['#field_suffix']) ? ' <span class="field-suffix">' . $element['#field_suffix'] . '</span>' : '';
+
+  switch ($element['#title_display']) {
+    case 'before':
+    case 'invisible':
+      $output .= ' ' . theme('form_element_label', $variables);
+      $output .= ' ' . $prefix . $element['#children'] . $suffix . "\n";
+      break;
+
+    case 'after':
+      $output .= ' ' . $prefix . $element['#children'] . $suffix;
+      $output .= ' ' . theme('form_element_label', $variables) . "\n";
+      break;
+
+    case 'none':
+    case 'attribute':
+      // Output no label and no required marker, only the children.
+      $output .= ' ' . $prefix . $element['#children'] . $suffix . "\n";
+      break;
+  }
+
+  if (!empty($element['#description'])) {
+    $output .= '<div class="description">' . $element['#description'] . "</div>\n";
+  }
+
+  $output .= "</div>\n";
+
+  return $output;
+}
+
+
+
+function guibik_form_node_form_alter(&$form, &$form_state){
+	// dsm($form, 'guibik_form_node_form_alter | $form');
+	// dsm($form_state, '$form_state');
+	
+	if(!isset($form['language']['#description']))
+		$form['language']['#description'] = t('Please consider to leave language in neutral state <strong>if you dont plan to translate this node</strong>, even if your content is (obviously) writed in some non neutral language. Then this node will always be visible.');
+	
+}
+

Некоторые файлы не были показаны из-за большого количества измененных файлов