From c5580ce746507b93c6dafd6d3d3830743673c993 Mon Sep 17 00:00:00 2001 From: Nicolas Le Goff Date: Wed, 7 Aug 2013 15:16:38 +0200 Subject: [PATCH 1/7] Fix #1408 JS performance selector issue --- templates/web/prod/upload/upload.html.twig | 3 ++- www/skins/prod/000000/prodcolor.css | 3 +++ www/skins/prod/959595/prodcolor.css | 3 +++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/templates/web/prod/upload/upload.html.twig b/templates/web/prod/upload/upload.html.twig index da8f480bbd..f9cc5145fc 100644 --- a/templates/web/prod/upload/upload.html.twig +++ b/templates/web/prod/upload/upload.html.twig @@ -386,7 +386,8 @@ $(document).ready(function () { //get form datas attached to the file data.formData = $.extend( data.context.find('input, select').serializeArray(), - UploaderManager.getSettingsBox().find('.collection-status:visible input, select').serializeArray() + $("input", $('.collection-status:visible', UploaderManager.getSettingsBox())).serializeArray(), + $("select", UploaderManager.getSettingsBox()).serializeArray() ); //remove current context diff --git a/www/skins/prod/000000/prodcolor.css b/www/skins/prod/000000/prodcolor.css index 9e90f3a4c3..0527b51257 100644 --- a/www/skins/prod/000000/prodcolor.css +++ b/www/skins/prod/000000/prodcolor.css @@ -4084,6 +4084,9 @@ dans l'onglet thesaurus : arbres, menus contextuels } #uploadBox .upload-record .infos-doc { + overflow: hidden; + -o-text-overflow: ellipsis; /* pour Opera 9 */ + text-overflow: ellipsis; color: #777777; height: 40px; } diff --git a/www/skins/prod/959595/prodcolor.css b/www/skins/prod/959595/prodcolor.css index 7f479bf1f8..3ba17801c0 100644 --- a/www/skins/prod/959595/prodcolor.css +++ b/www/skins/prod/959595/prodcolor.css @@ -4218,6 +4218,9 @@ dans l'onglet thesaurus : arbres, menus contextuels } #uploadBox .upload-record .infos-doc { + overflow: hidden; + -o-text-overflow: ellipsis; /* pour Opera 9 */ + text-overflow: ellipsis; color: #777777; height: 40px; } From c4bee9372287286c48911806c19afc90cfa16862 Mon Sep 17 00:00:00 2001 From: Nicolas Le Goff Date: Wed, 7 Aug 2013 17:42:49 +0200 Subject: [PATCH 2/7] Fix #1320 Js issue while rendering results --- templates/web/prod/index.html.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/web/prod/index.html.twig b/templates/web/prod/index.html.twig index 7aa3f0299a..bea73022e5 100644 --- a/templates/web/prod/index.html.twig +++ b/templates/web/prod/index.html.twig @@ -277,7 +277,7 @@
-
+
From 1c94e12a8f694f9f52228e03d6b017eda11aacf9 Mon Sep 17 00:00:00 2001 From: Romain Neutron Date: Wed, 7 Aug 2013 12:55:44 +0200 Subject: [PATCH 3/7] Cleanup temporary files --- composer.json | 2 +- lib/Alchemy/Phrasea/Command/RecordAdd.php | 5 +++-- lib/Alchemy/Phrasea/Core/Configuration/Configuration.php | 1 + .../Core/Provider/TemporaryFilesystemServiceProvider.php | 6 +++++- .../Provider/TemporaryFilesystemServiceProviderTest.php | 2 +- 5 files changed, 11 insertions(+), 5 deletions(-) diff --git a/composer.json b/composer.json index 6e12f90c7e..9f556aab08 100644 --- a/composer.json +++ b/composer.json @@ -28,7 +28,7 @@ "neutron/silex-filesystem-provider": "~1.0", "neutron/sphinxsearch-api" : "~2.0.6", "neutron/recaptcha" : "~0.1.0", - "neutron/temporary-filesystem" : "~2.0", + "neutron/temporary-filesystem" : "~2.1", "php-xpdf/php-xpdf" : "~0.2.1", "phpexiftool/phpexiftool" : "~0.2, >=0.2.2", "silex/silex" : "~1.0.0", diff --git a/lib/Alchemy/Phrasea/Command/RecordAdd.php b/lib/Alchemy/Phrasea/Command/RecordAdd.php index c3c0ef36c6..ba5184266b 100644 --- a/lib/Alchemy/Phrasea/Command/RecordAdd.php +++ b/lib/Alchemy/Phrasea/Command/RecordAdd.php @@ -81,7 +81,7 @@ class RecordAdd extends Command if ($input->getOption('in-place') !== '1') { $originalName = pathinfo($file, PATHINFO_BASENAME); - $tempfile = tempnam(sys_get_temp_dir(), 'addrecord') . '.' . pathinfo($file, PATHINFO_EXTENSION); + $tempfile = $this->container['temporary-filesystem']->createTemporaryFile('add_record', null, pathinfo($file, PATHINFO_EXTENSION)); $this->container['monolog']->addInfo(sprintf('copy file from `%s` to temporary `%s`', $file, $tempfile)); $this->container['filesystem']->copy($file, $tempfile, true); $file = $tempfile; @@ -97,6 +97,7 @@ class RecordAdd extends Command if ($input->getOption('force')) { switch ($input->getOption('force')) { default: + $this->container['temporary-filesystem']->clean('add_record'); throw new \InvalidArgumentException(sprintf('`%s` is not a valid force option', $input->getOption('force'))); break; case 'record': @@ -130,7 +131,7 @@ class RecordAdd extends Command if ($tempfile) { $this->container['monolog']->addInfo(sprintf('Remove temporary file `%s`', $tempfile)); - $this->container['filesystem']->remove($tempfile); + $this->container['temporary-filesystem']->clean('add_record'); } return; diff --git a/lib/Alchemy/Phrasea/Core/Configuration/Configuration.php b/lib/Alchemy/Phrasea/Core/Configuration/Configuration.php index e5c74875e7..e393cf481d 100644 --- a/lib/Alchemy/Phrasea/Core/Configuration/Configuration.php +++ b/lib/Alchemy/Phrasea/Core/Configuration/Configuration.php @@ -231,6 +231,7 @@ class Configuration implements ConfigurationInterface } } + unlink($tmpFile); throw new RuntimeException(sprintf('Unable to write %s', $file)); } diff --git a/lib/Alchemy/Phrasea/Core/Provider/TemporaryFilesystemServiceProvider.php b/lib/Alchemy/Phrasea/Core/Provider/TemporaryFilesystemServiceProvider.php index 33ebf9d38a..73e933b32b 100644 --- a/lib/Alchemy/Phrasea/Core/Provider/TemporaryFilesystemServiceProvider.php +++ b/lib/Alchemy/Phrasea/Core/Provider/TemporaryFilesystemServiceProvider.php @@ -12,6 +12,7 @@ namespace Alchemy\Phrasea\Core\Provider; use Neutron\TemporaryFilesystem\TemporaryFilesystem; +use Neutron\TemporaryFilesystem\Manager; use Silex\Application; use Silex\ServiceProviderInterface; @@ -19,9 +20,12 @@ class TemporaryFilesystemServiceProvider implements ServiceProviderInterface { public function register(Application $app) { - $app['temporary-filesystem'] = $app->share(function (Application $app) { + $app['temporary-filesystem.temporary-fs'] = $app->share(function (Application $app) { return new TemporaryFilesystem($app['filesystem']); }); + $app['temporary-filesystem'] = $app->share(function (Application $app) { + return new Manager($app['temporary-filesystem.temporary-fs'], $app['filesystem']); + }); } public function boot(Application $app) diff --git a/tests/Alchemy/Tests/Phrasea/Core/Provider/TemporaryFilesystemServiceProviderTest.php b/tests/Alchemy/Tests/Phrasea/Core/Provider/TemporaryFilesystemServiceProviderTest.php index 89b39e1c47..b3535f5682 100644 --- a/tests/Alchemy/Tests/Phrasea/Core/Provider/TemporaryFilesystemServiceProviderTest.php +++ b/tests/Alchemy/Tests/Phrasea/Core/Provider/TemporaryFilesystemServiceProviderTest.php @@ -10,7 +10,7 @@ class TemporaryFilesystemServiceProvidertest extends ServiceProviderTestCase public function provideServiceDescription() { return array( - array('Alchemy\Phrasea\Core\Provider\TemporaryFilesystemServiceProvider', 'temporary-filesystem', 'Neutron\TemporaryFilesystem\TemporaryFilesystem'), + array('Alchemy\Phrasea\Core\Provider\TemporaryFilesystemServiceProvider', 'temporary-filesystem', 'Neutron\TemporaryFilesystem\TemporaryFilesystemInterface'), ); } } From 641892ada26d110bd07820673db1d561178a1929 Mon Sep 17 00:00:00 2001 From: Nicolas Le Goff Date: Wed, 7 Aug 2013 18:15:32 +0200 Subject: [PATCH 4/7] Fix #1410 CSS button height issue in search form --- www/skins/prod/000000/prodcolor.css | 32 +++++-------------- www/skins/prod/959595/prodcolor.css | 49 +++++------------------------ 2 files changed, 15 insertions(+), 66 deletions(-) diff --git a/www/skins/prod/000000/prodcolor.css b/www/skins/prod/000000/prodcolor.css index 8d02999634..b87330ba80 100644 --- a/www/skins/prod/000000/prodcolor.css +++ b/www/skins/prod/000000/prodcolor.css @@ -490,34 +490,16 @@ span.ww_winTitle { /******* FORMULAIRE DE RECHERCHE **********************************************/ -#searchForm > button.btn { - font-family: verdana,"Helvetica Neue",Helvetica,Arial,sans-serif; - font-size: 12px; - font-weight: bold; - -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); +#searchForm .input-append .btn { + border:none; } -#searchForm > button.btn-inverse { - width: 110px; +#searchForm .input-append a.btn { + height: 22px; +} + +#searchForm .input-append button.btn { height: 30px; - margin-left: 4px; - *border: 1px solid #515151; - color: #AAAAAA; - font-weight: bold; -} - -#searchForm > button.btn-inverse:hover { - color: #FFFFFF; -} - -#searchForm label { - color: #FFFFFF; -} - -#searchForm #recordtype_sel { - margin-left: 10px; } /******* PRESENTATION DE MINIATURES *******************************************/ diff --git a/www/skins/prod/959595/prodcolor.css b/www/skins/prod/959595/prodcolor.css index 5e3d88eef5..21b9fdc31f 100644 --- a/www/skins/prod/959595/prodcolor.css +++ b/www/skins/prod/959595/prodcolor.css @@ -29,7 +29,7 @@ label { } legend { - #333333; + color: #333333; width: auto; border: none; } @@ -501,49 +501,16 @@ span.ww_winTitle { /******* FORMULAIRE DE RECHERCHE **********************************************/ -#searchForm > button.btn { - font-family: verdana,"Helvetica Neue",Helvetica,Arial,sans-serif; - font-size: 12px; - font-weight: bold; - -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); +#searchForm .input-append .btn { + border:none; } -#searchForm > button.btn-inverse { - width: 110px; +#searchForm .input-append a.btn { + height: 22px; +} + +#searchForm .input-append button.btn { height: 30px; - margin-left: 4px; - background-color: #D6D6D6; - *background-color: #D6D6D6; - background-image: -ms-linear-gradient(top, #FFFFFF, #D6D6D6); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#FFFFFF), to(#D6D6D6)); - background-image: -webkit-linear-gradient(top, #FFFFFF, #D6D6D6); - background-image: -o-linear-gradient(top, #FFFFFF, #D6D6D6); - background-image: linear-gradient(top, #FFFFFF, #D6D6D6); - background-image: -moz-linear-gradient(top, #FFFFFF, #D6D6D6); - border-color: #D6D6D6 #D6D6D6 #bfbfbf; - border-bottom-color: #b3b3b3; - filter: progid:dximagetransform.microsoft.gradient(startColorstr='#FFFFFF', endColorstr='#D6D6D6', GradientType=0); - filter: progid:dximagetransform.microsoft.gradient(enabled=false); - *border: 1px solid #666666; - text-shadow: none; - color: #777777; -} - -#searchForm > button.btn-inverse:hover { - background-color: #D6D6D6; - *background-color: #D6D6D6; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - color: #FFFFFF; -} - -#searchForm label { - color: #333333; -} - -#searchForm #recordtype_sel { - margin-left: 10px; } /******* PRESENTATION DE MINIATURES *******************************************/ From a62de344169cab812c57f6f0fbab99f56601fc1b Mon Sep 17 00:00:00 2001 From: Nicolas Le Goff Date: Wed, 7 Aug 2013 18:36:53 +0200 Subject: [PATCH 5/7] Enhance homepage & display instance title --- templates/web/login/include/cooliris-content.html.twig | 6 +++--- templates/web/login/index.html.twig | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/templates/web/login/include/cooliris-content.html.twig b/templates/web/login/include/cooliris-content.html.twig index 2f813b409f..a8c1781137 100644 --- a/templates/web/login/include/cooliris-content.html.twig +++ b/templates/web/login/include/cooliris-content.html.twig @@ -1,6 +1,6 @@
-
- + @@ -14,7 +14,7 @@ src="https://apps.cooliris.com/embed/cooliris.swf" flashvars="feed=/feeds/cooliris/&glowColor=#0077BC&style=dark&backgroundColor=#000000&showChrome=false&showEMbed=false&showSearch=false" width="100%" - height="360" + height="100%" allowFullScreen="true" allowScriptAccess="always"> diff --git a/templates/web/login/index.html.twig b/templates/web/login/index.html.twig index 39bab2efd2..c69c67b529 100644 --- a/templates/web/login/index.html.twig +++ b/templates/web/login/index.html.twig @@ -3,8 +3,8 @@ {% import "common/macros.html.twig" as macro %} {% import "login/common/macros.html.twig" as auth_macro %} -{% block title %} - {{ instance_title }} +{% block main_title %} + {{ instance_title|default('Phraseanet') }} {% endblock %} {% block header_rss %} From a7690d3cacb679146feb329a215d8a30b8502820 Mon Sep 17 00:00:00 2001 From: Nicolas Le Goff Date: Wed, 7 Aug 2013 18:47:34 +0200 Subject: [PATCH 6/7] Fix #1409 Css issue for record caption in lightbox --- templates/web/lightbox/IE6/feed.html.twig | 6 ++--- templates/web/lightbox/IE6/validate.html.twig | 6 ++--- templates/web/lightbox/feed.html.twig | 6 ++--- templates/web/lightbox/validate.html.twig | 6 ++--- www/skins/lightbox/jquery.lightbox.ie6.js | 24 +++++++++---------- www/skins/lightbox/jquery.lightbox.js | 24 +++++++++---------- www/skins/lightbox/lightbox.css | 6 ++--- www/skins/lightbox/lightboxie6.css | 2 +- 8 files changed, 40 insertions(+), 40 deletions(-) diff --git a/templates/web/lightbox/IE6/feed.html.twig b/templates/web/lightbox/IE6/feed.html.twig index 8d5ab5ac33..654cdd89f3 100644 --- a/templates/web/lightbox/IE6/feed.html.twig +++ b/templates/web/lightbox/IE6/feed.html.twig @@ -32,7 +32,7 @@ -
+ -
+
@@ -80,7 +80,7 @@
-
+ -
+ -
+
@@ -92,7 +92,7 @@
-
+ -
+ -
+
@@ -80,7 +80,7 @@
-
+ -
+ -
+
@@ -95,7 +95,7 @@
-
+