Download & Extend

Path is never empty in option summary.

Project:Views
Version:7.x-3.x-dev
Component:User interface
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)
Issue tags:BADCamp2012UX, Novice, Usability, VDC

Issue Summary

So currently we have this code determining what is displayed for an empty path in the edit UI.

<?php
  $path
= strip_tags('/' . $this->getOption('path'));

  if (empty(
$path)) {
   
$path = t('None');
  }
?>

Because a '/' is always appended to the path, it's never empty. So for an empty path we are just left with the '/' character.

Comments

#1

Status:active» needs review

Here is a patch with the text changed to 'No path defined', based on the Views usability study feedback.

We should probably add a test for this too.

AttachmentSizeStatusTest resultOperations
views-empty-path.patch745 bytesIdlePASSED: [[SimpleTest]]: [MySQL] 46,870 pass(es).View details

#2

Status:needs review» reviewed & tested by the community

This looks perfect

I guess screenshots would show how great this actual improvement is.

#3

Status:reviewed & tested by the community» needs review

Yhea, this is a bit of an unwritten rule. But we generally really like to have screens before UX improvements are RTBC, just to provide that last check.

I would love if we can actually not use "defined", and just say "No path is set"

#4

Issue tags:+BADCamp2012UX, +Usability

#5

Sounds good to me!

AttachmentSizeStatusTest resultOperations
1831142-5.patch744 bytesIdlePASSED: [[SimpleTest]]: [MySQL] 47,617 pass(es).View details

#6

Title:path is never empty in option summary.» Path is never empty in option summary.

#7

Fine, here is one.

AttachmentSizeStatusTest resultOperations
before.png7.66 KBIgnored: Check issue status.NoneNone
after.png22.56 KBIgnored: Check issue status.NoneNone

#8

Status:needs review» reviewed & tested by the community

:)

#9

Too late now, but +1 from me. This came up in 2 of my sessions. Plus '/' is a tiny target area!

#10

Is this worth adding a test for per #2?

#11

Let's do it, you never know.

AttachmentSizeStatusTest resultOperations
drupal-1831142-11.patch2.1 KBIdlePASSED: [[SimpleTest]]: [MySQL] 48,021 pass(es).View details

#12

Status:reviewed & tested by the community» fixed

Committed/pushed to 8.x, thanks!

#13

Will this get ported to 7.x?

#14

Project:Drupal core» Views
Version:8.x-dev» 7.x-3.x-dev
Component:views_ui.module» User interface

No reason it cant

#15

Status:fixed» active

#16

Issue tags:+Novice

Good point! That is nothing really complicated to implement.

#17

Status:active» needs review

Drupal 7 backport ready for review.

AttachmentSizeStatusTest resultOperations
views-path-change-1831142-17.patch1000 bytesIdlePASSED: [[SimpleTest]]: [MySQL] 1,603 pass(es).View details

#18

Status:needs review» reviewed & tested by the community

Let's not backport the test unless someone is willing to take the effort.

+++ b/plugins/views_plugin_display_page.incundefined
@@ -251,9 +251,13 @@ class views_plugin_display_page extends views_plugin_display {
+    ¶

We shouldn't introduce that whitespace here.

#19

Thanks for spotting that. I've updated the patch to remove the extra whitespace. Patch applies without warning now.

AttachmentSizeStatusTest resultOperations
views-path-change-1831142-19.patch993 bytesIdlePASSED: [[SimpleTest]]: [MySQL] 1,603 pass(es).View details

#20

Thanks. Its seems to work ok for me, it applies and works fine without any warnings or errors.

#21

Status:reviewed & tested by the community» fixed

Awesome! Committed and pushed

#23

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

nobody click here