Bug 36912

Summary: Add more spans/classes to member-display-address-style.inc for additional styling
Product: Koha Reporter: Lucas Gass (lukeg) <lucas>
Component: PatronsAssignee: Lucas Gass (lukeg) <lucas>
Status: RESOLVED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: david, gmcharlt, kyle.m.hall, Laura.escamilla
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
This enhancement adds spans and classes for customizing the styling of a patron's main address when using IntranetUserCSS. Example: .patronaddress1 { .streetnumber { color: blue; } .address1 { color: green; } .roadtype { color: pink; } } .patronaddress2 { color: lightgreen; } .patroncity { .city { color: orange; } .state { color: brown; } .zipcode { color: limegreen; } .comma { color: teal; } .country { color: red; } }
Version(s) released in:
24.11.00
Circulation function:
Attachments: Bug 36912: Add more spans/classes to member-display-address-style.inc
Bug 36912: Add more spans/classes to member-display-address-style.inc

Description Lucas Gass (lukeg) 2024-05-21 20:36:11 UTC
In member-display-address-style.inc the address could use some more spans/classes to make it easier to style certain parts of the address.
Comment 1 Lucas Gass (lukeg) 2024-05-21 20:41:37 UTC
Created attachment 166988 [details] [review]
Bug 36912: Add more spans/classes to member-display-address-style.inc

To test:
1. APPLY PATCH
2. Make an AV for ROADTYPE
3. Find a patron record and make sure the entire 'Main address' portin is filled out. ( street number, street type, address, address 2, ZIP, City, State, and Country )
4. For easier testing you can add this test CSS to IntranetUSerCSS:

.patronaddress1 {
  .streetnumber {
  	color: blue;
  }
  .address1 {
  	color: green;
  }
  .roadtype {
    color: pink;
  }
}

.patronaddress2 {
	color: lightgreen;
}

.patroncity {
  .city {
     color: orange;
  }
  .state {
     color: brown;
  }
  .zipcode {
     color: limegreen;
  }
  .comma {
     color: teal;
  }
  .country {
     color: red;
  }
}

5. Go to the patron's record and look aty the brief info. you should see classes for everything in the address block. If you added the CSS from above everything should be colored differently.
6. Find the system pref 'AddressFormat' and test everything in US style, French style, and German style.
Comment 2 Laura Escamilla 2024-05-23 11:02:35 UTC
Created attachment 167098 [details] [review]
Bug 36912: Add more spans/classes to member-display-address-style.inc

To test:
1. APPLY PATCH
2. Make an AV for ROADTYPE
3. Find a patron record and make sure the entire 'Main address' portin is filled out. ( street number, street type, address, address 2, ZIP, City, State, and Country )
4. For easier testing you can add this test CSS to IntranetUSerCSS:

.patronaddress1 {
  .streetnumber {
  	color: blue;
  }
  .address1 {
  	color: green;
  }
  .roadtype {
    color: pink;
  }
}

.patronaddress2 {
	color: lightgreen;
}

.patroncity {
  .city {
     color: orange;
  }
  .state {
     color: brown;
  }
  .zipcode {
     color: limegreen;
  }
  .comma {
     color: teal;
  }
  .country {
     color: red;
  }
}

5. Go to the patron's record and look aty the brief info. you should see classes for everything in the address block. If you added the CSS from above everything should be colored differently.
6. Find the system pref 'AddressFormat' and test everything in US style, French style, and German style.

Signed-off-by: Laurae <laura.escamilla@bywatersolutions.com>
Comment 3 Katrin Fischer 2024-06-27 15:09:17 UTC
Picked from QA queue for main.

</psan>[%~ END ~%] 
Fixed inline.
Comment 4 Katrin Fischer 2024-06-27 15:26:50 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 5 Lucas Gass (lukeg) 2024-07-19 15:47:39 UTC
Enhancement will not be backported to 24.05.x