if

Singapore Arbitration Centre to open office at GIFT City

The Arbitration and Conciliation Act lays down a time frame of 18 months for the disputes to be resolved.




if

Axis Bank unveils India’s first certified green bond on LSE




if

Helpshift raises $23 m in Series B funding




if

‘Investment norms for NIIF may be tweaked’




if

Sensex, Nifty close higher amid buying in heavyweight stocks, firm global cues

The sensex rose 144.31 points to settle at 81,611.41 and Nifty increased 16.50 points to close at 24,998.45




if

Sensex rises 592 points, Nifty settles above 25K on gains in IT, banking shares

Capitalisation of BSE-listed companies jumped by nearly ₹1.35 lakh crore to ₹4,63,62,781.71




if

Sensex, Nifty climb in early trade on buying in IT, bank stocks

Equity indices rise on IT and bank stocks, sharp Brent crude cut; HCL Tech reports strong Q2 earnings




if

Sensex, Nifty fall for 3rd day amid foreign fund exodus

Intense selling in realty, auto, consumer discretionary and consumer durable stocks also dragged the markets lower




if

Sensex, Nifty slump as unabated foreign fund outflows drag markets lower

The BSE Sensex tanked 570.45 points to 80,436.16 in early trade. The NSE Nifty slumped 178.3 points to 24,571.55




if

Sensex, Nifty tumble over 1% on weak global cues, foreign fund exodus

Extending its previous day's decline, the BSE Sensex plummeted 930.55 points or 1.15% to settle at 80,220.72. NSE Nifty tumbled 309 points or 1.25% to 24,472.10.




if

Sensex, Nifty tank nearly 1% amid sharp fall in IndusInd Bank, foreign fund outflows

The BSE Sensex plummeted 662.87 points or 0.83% to settle at 79,402.29. The NSE Nifty tanked 218.60 points or 0.90% to 24,180.80




if

Sensex, Nifty decline on selling in banking, financial stocks; weak global trends

The BSE Sensex tumbled 426.85 points or 0.53% to settle at 79,942.18. The NSE Nifty dropped 126 points or 0.51% to 24,340.85




if

Sensex, Nifty decline on unabated foreign fund outflows, selling in IT stocks

Falling for the second day in a row, the BSE Sensex tumbled 553.12 points or 0.69% to settle at 79,389.06. During the day, it slumped 654.25 points or 0.81% to 79,287.93




if

Muhurat trading: Sensex, Nifty advance to start Samvat 2081 on a high

Muhurat trading is a one-hour, symbolic trading session conducted by stock exchanges on the occasion of Diwali, marking the start of the new Samvat year.




if

Sensex, Nifty plunge in early trade dragged by Reliance Industries

Relentless selling by foreign investors also dampened the sentiments in the equity market




if

Sensex tanks 942 points; Nifty plunges below 24K on heavy selling in Reliance, banking shares

The 30-share BSE Sensex tumbled 941.88 points or 1.18% to settle at 78,782.24, the lowest closing level since August 6




if

Sensex, Nifty climb in early trade on buying in IT stocks

Equity indices rise on IT stocks, U.S. market rally as Sensex up 338.1 points and Nifty up 101.5 points




if

Sensex, Nifty surge over 1% on heavy buying in IT stocks as Donald Trump wins U.S. polls

Stock markets surge over 1% as Sensex gains 901 points on Trump’s U.S. election win, boosting IT and pharma shares




if

Sensex, Nifty fall over 1 %, snap two-day rally ahead of U.S. Fed interest rate decision

Stock markets tumble over 1% as investors await U.S. Fed decision, with Sensex and Nifty dropping significantly




if

No question of reviving ties with BJP, clarifies AIADMK

Former Fisheries Minister D. Jayakumar told journalists at the party headquarters that the AIADMK would have no truck with the BJP not only in 2026 but also in other elections in the future




if

Co-encapsulation of organic polymers and inorganic superparamagnetic iron oxide colloidal crystals requires matched diffusion time scales

Soft Matter, 2024, 20,8312-8325
DOI: 10.1039/D4SM00935E, Paper
Open Access
Brian K. Wilson, Robert K. Prud’homme
Composite nanoparticles co-encapsulate organic materials with inorganic primary colloids. Producing “stoichiometric NPs”, where all NPs contain organic and inorganic species at similar ratios, requires matched diffusion-aggregation time scale.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Stress amplification and relaxation imaging around cracks in nanocomposite gels using ultrasound elastography

Soft Matter, 2024, Advance Article
DOI: 10.1039/D4SM00909F, Paper
H. Le Blay, T. Deffieux, L. Laiarinandrasana, M. Tanter, A. Marcellan
Stress visualization around cracks in NC gels was performed using ultrasonic elastography. Temporal and spatial mapping are performed non-invasively. Over time, the stress gradient is erased by large-scale reorganization of the polymer network.
To cite this article before page numbers are assigned, use the DOI form of citation above.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Network interactions simultaneously enhance stiffness and lubricity of triple-network hydrogels

Soft Matter, 2024, Advance Article
DOI: 10.1039/D4SM00969J, Paper
Nabila Ali, Connor J. Demott, Olivia F. Dingus, Melissa A. Grunlan, Alison C. Dunn
Tough hydrogels with a charge-variable third network were assessed for biomimicking lubricity in both water and FBS solution.
To cite this article before page numbers are assigned, use the DOI form of citation above.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Emulsifying mechanisms of phospholipids in high-pressure homogenization of perfluorocarbon nanoemulsions

Soft Matter, 2024, 20,8373-8384
DOI: 10.1039/D4SM00828F, Paper
Open Access
  This article is licensed under a Creative Commons Attribution 3.0 Unported Licence.
Larissa J. Lubitz, Harden Rieger, Gero Leneweit
An optimized PFC/W emulsion contains 1 mM lipid per 1% (v/v) dispersed phase for an emulsifying monolayer; higher ratios result in triple layers. Low viscosity ratios ηD/ηC ≤ 5 and low PFC volume fractions lead to smaller monodisperse droplets.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

The surface diffusivity of nanoparticles physically adsorbed at a solid–liquid interface

Soft Matter, 2024, 20,8446-8454
DOI: 10.1039/D4SM00992D, Paper
Troy Singletary, Nima Iranmanesh, Carlos E. Colosqui
This work proposes an analytical model considering the effects of hydrodynamic drag and energy barriers induced by liquid solvation forces to predict the in-plane translational diffusivity of a nanoparticle physically adsorbed on a wetted surface.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Influence of counterion type on the scattering of a semiflexible polyelectrolyte

Soft Matter, 2024, 20,8610-8620
DOI: 10.1039/D4SM00874J, Paper
Open Access
Anish Gulati, Jack F. Douglas, Olga Matsarskaia, Carlos G. Lopez
Understanding the influence of counterion and backbone solvation on the conformational and thermodynamic properties of polyelectrolytes in solution is one of the main open challenges in polyelectrolyte science.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Pairing-specific microstructure in depletion gels of bidisperse colloids

Soft Matter, 2024, Advance Article
DOI: 10.1039/D4SM00811A, Paper
Open Access
Rony A. Waheibi, Lilian C. Hsiao
We report the ensemble-averaged and pairing-specific network microstructure formed by short-range depletion attractions in bidisperse hard sphere-like colloidal systems.
To cite this article before page numbers are assigned, use the DOI form of citation above.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Percolation transitions in a binary mixture of active Brownian particles with different softness

Soft Matter, 2024, Advance Article
DOI: 10.1039/D4SM00981A, Paper
Monika Sanoria, Raghunath Chelakkot, Amitabha Nandi
Homogeneous active Brownian particle (ABP) systems with purely repulsive interactions are considered to exhibit a simple phase behavior, but various physical attributes of active entities can lead to variation in the collective dynamics.
To cite this article before page numbers are assigned, use the DOI form of citation above.
The content of this RSS Feed (c) The Royal Society of Chemistry




if

A generalized model for predicting different morphologies of bacterial swarming on a porous solid surface

Soft Matter, 2024, Accepted Manuscript
DOI: 10.1039/D4SM01072H, Paper
Uttam Kumar, Pushpavanam Subramaniam
In this study, we develop a comprehensive two-phase model to analyze the dynamics of bacterial swarming on porous substrates. The two distinct phases under consideration are the cell and aqueous...
The content of this RSS Feed (c) The Royal Society of Chemistry




if

Beautiful Scrolling Experiences – Without Libraries

Michelle Barker appears as one of a heavenly host, coming forth with scroll in hand to pronounce an end to janky scrolljacking! Unto us a new specification is born, in the city of TimBL, and its name shall be called Scroll Snap.


Sponsor: Order any Standard paperback(s) and get a surprise gift card in the box for YOU. While supplies last, from your pals at A Book Apart!


One area where the web has traditionally lagged behind native platforms is the perceived “slickness” of the app experience. In part, this perception comes from the way the UI responds to user interactions – including the act of scrolling through content.

Faced with the limitations of the web platform, developers frequently reach for JavaScript libraries and frameworks to alter the experience of scrolling a web page – sometimes called “scroll-jacking” – not always a good thing if implemented without due consideration of the user experience. More libraries can also lead to page bloat, and drag down a site’s performance. But with the relatively new CSS Scroll Snap specification, we have the ability to control the scrolling behaviour of a web page (to a degree) using web standards – without resorting to heavy libraries. Let’s take a look at how.

Scroll Snap

A user can control the scroll position of a web page in a number of ways, such as using a mouse, touch gesture or arrow keys. In contrast to a linear scrolling experience, where the rate of scroll reflects the rate of the controller, the Scroll Snap specification enables a web page to snap to specific points as the user scrolls. For this, we need a fixed-height element to act as the scroll container, and the direct children of that element will determine the snap points. To demonstrate this, here is some example HTML, which consists of a <div> containing four <section> elements:

<div class="scroll-container">
  <section>
    <h2>Section 1</h2>
  </section>
  <section>
    <h2>Section 2</h2>
  </section>
  <section>
    <h2>Section 3</h2>
  </section>
  <section>
    <h2>Section 4</h2>
  </section>
</div>

Scroll snapping requires the presence of two main CSS properties: scroll-snap-type and scroll-snap-align. scroll-snap-type applies to the scroll container element, and takes two keyword values. It tells the browser:

  • The direction to snap
  • Whether snapping is mandatory

scroll-snap-align is applied to the child elements – in this case our <section>s.

We also need to set a fixed height on the scroll container, and set the relevant overflow property to scroll.

.scroll-container {
  height: 100vh;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
}

section {
  height: 100vh;
  scroll-snap-align: center;
}

In the above example, I’m setting the direction in the scroll-snap-type property to y to specify vertical snapping. The second value specifies that snapping is mandatory. This means that when the user stops scrolling their scroll position will always snap to the nearest snap point. The alternative value is proximity, which determines that the user’s scroll position will be snapped only if they stop scrolling in the proximity of a snap point. (It’s down to the browser to determine what it considers to be the proximity threshold.)

If you have content of indeterminate length, which might feasibly be larger than the height of the scroll container (in this case 100vh), then using a value of mandatory can cause some content to be hidden above or below the visible area, so is not recommended. But if you know that your content will always fit within the viewport, then mandatory can produce a more consistent user experience.

See the Pen Simple scroll-snap example by Michelle Barker (@michellebarker) on CodePen.

In this example I’m setting both the scroll container and each of the sections to a height of 100vh, which affects the scroll experience of the entire web page. But scroll snapping can also be implemented on smaller components too. Setting scroll snapping on the x-axis (or inline axis) can produce something like a carousel effect.

In this demo, you can scroll horizontally scroll through the sections:

See the Pen Carousel-style scroll-snap example by Michelle Barker (@michellebarker) on CodePen.

The Intersection Observer API

By implementing the CSS above, our web page already has a more native-like feel to it. To improve upon this further we could add some scroll-based transitions and animations. We’ll need to employ a bit of Javascript for this, using the Intersection Observer API. This allows us to create an observer that watches for elements intersecting with the viewport, triggering a callback function when this occurs. It is more efficient than libraries that rely on continuously listening for scroll events.

We can create an observer that watches for each of our scroll sections coming in and out of view:

const sections = [...document.querySelectorAll('section')]

const options = {
  rootMargin: '0px',
  threshold: 0.25
}

const callback = (entries) => {
  entries.forEach((entry) => {
    if (entry.intersectionRatio >= 0.25) {
      target.classList.add("is-visible");
    } else {
      target.classList.remove("is-visible");
    }
  })
}

const observer = new IntersectionObserver(callback, options)

sections.forEach((section, index) => {
  observer.observe(section)
})

In this example, a callback function is triggered whenever one of our sections intersects the container by 25% (using the threshold option). The callback adds a class of is-visible to the section if it is at least 25% in view when the intersection occurs (which will take effect when the element is coming into view), and removes it otherwise (when the element is moving out of view). Then we can add some CSS to transition in the content for each of those sections:

section .content {
  opacity: 0:
}

section.is-visible .content {
  opacity: 1;
  transition: opacity 1000ms:
}

This demo shows it in action:

See the Pen Scrolling with Intersection Observer by Michelle Barker (@michellebarker) on CodePen.

You could, of course, implement some much more fancy transition and animation effects in CSS or JS!

As an aside, it’s worth pointing out that, in practice, we shouldn’t be setting opacity: 0 as the default without considering the experience if JavaScript fails to load. In this case, the user would see no content at all! There are different ways to handle this: We could add a .no-js class to the body (which we remove on load with JS), and set default styles on it, or we could set the initial style (before transition) with JS instead of CSS.

Position: sticky

There’s one more CSS property that I think has the potential to aid the scroll experience, and that’s the position property. Unlike position: fixed, which locks the position of an element relative to the nearest relative ancestor and doesn’t change, position: sticky is more like a temporary lock. An element with a position value of sticky will become fixed only until it reaches the threshold of its parent, at which point it resumes relative positioning.

By “sticking” some elements within scroll sections we can give the impression of them being tied to the action of scrolling between sections. It’s pretty cool that we can instruct an element to respond to it’s position within a container with CSS alone!

Browser support and fallbacks

The scroll-snap-type and scroll-snap-align properties are fairly well-supported. The former requires a prefix for Edge and IE, and older versions of Safari do not support axis values. In newer versions of Safari it works quite well. Intersection Observer similarly has a good level of support, with the exception of IE.

By wrapping our scroll-related code in a feature query we can provide a regular scrolling experience as a fallback for users of older browsers, where accessing the content is most important. Browsers that do not support scroll-snap-type with an axis value would simply scroll as normal.

@supports (scroll-snap-type: y mandatory) {
  .scroll-container {
    height: 100vh;
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
  }

  section {
    height: 100vh;
    scroll-snap-align: center;
  }
}

The above code would exclude MS Edge and IE, as they don’t support axis values. If you wanted to support them you could do so using a vendor prefix, and using @supports (scroll-snap-type: mandatory) instead.

Putting it all together

This demo combines all three of the effects discussed in this article.

Summary

Spending time on scroll-based styling might seem silly or frivolous to some. But I believe it’s an important part of positioning the web as a viable alternative to native applications, keeping it open and accessible. While these new CSS features don’t offer all of the control we might expect with a fully featured JS library, they have a major advantage: simplicity and reliability. By utilising web standards where possible, we can have the best of both worlds: Slick and eye-catching sites that satisfy clients’ expectations, with the added benefit of better performance for users.


About the author

Michelle is a Lead Front End Developer at Bristol web agency Atomic Smash, author of front-end blog CSS { In Real Life }, and a Mozilla Tech Speaker. She has written articles for CSS Tricks, Smashing Magazine, and Web Designer Magazine, to name a few. She enjoys experimenting with new CSS features and helping others learn about them.

More articles by Michelle




if

Gift Giving to the World (Wide Web)

Frances Berriman asks us to give the gift of consideration to those who are using the web on constricted devices such as low-end smart phones or feature phones. Christmas is a time of good will to all, and as Bugsy Malone reminds us, you give a little love and it all comes back to you.


If I was given the job of Father Christmas with all my human limitations, apparently it would take me something like 6 months at non-stop full speed to deliver gifts to every kid on the planet. The real Father Christmas has the luxury of magic when it comes to delivering millions of gifts in just one night, but the only magical platform at my disposal is the world wide web, so I propose switching to digital gift cards and saving the reindeer feed.

300 million people are set to come online for the very first time in 2020, and a majority of those will be doing so via mobile phones (smart- and feature-phones). If we want those new users to have a great time online, spending those gift cards, we need to start thinking about their needs and limitations.

Suit up

We might not be hopping on the sleigh for these deliveries, but let’s suit up for the journey and get the tools we need to start testing and checking how our online gift-receivers will be enjoying their online shopping experience.

Of course, the variety of phones and OSs out there is huge and varied, but we have a few options out there to get a sense for the median. Here’s a few suggestions on where to start:

  • Never has there been a better time to advocate at your workplace for a device testing suite or lab.
  • You can also just pick up a low-end phone for a few bucks and spend some real time using it and getting a sense for how it feels to live with it every day. May I suggest the Nokia 2 or the Moto E6 - both very representative devices of the sort our new visitors will be on.
  • You’ve also got WebPageTest.org at your disposal, where you can emulate various phones and see your sites rendered in real-time to get a sense of what an experience may look like for your users.
  • You’ll also want to set yourself some goals. A performance budget, for example, is a good way to know if the code you’re shipping hits the mark in a more programmatic way.

Gift wrap

Many of us began our internet lives on desktop machines, and thanks to Moore’s law, these machines have been getting ever more powerful every year with more CPUs and memory at our disposal. The mobile phone landscape somewhat resets us on what hardware capacity is available on the client-side of our code, so it’s time to lighten the load.

What we see in the landscape of phones today is a huge spread of capabilities and CPU speeds, storage capacity and memory. And the gap between the haves and the have-nots is widening, so we have a huge task to deal with in meeting the needs of such a varied audience.

As far as possible, we should try to:

  • Keep processing off the client - do anything you can server-side. Consider a server-side render (hold the <script>, thanks) for anything relatively static (including cached frequent queries and results) to keep client-side JavaScript to the minimum. This way you’re spending your CPU, not the user’s.
  • Avoid sending everything you have to to the end user. Mobile-first access also means data-plan-first access for many, which means they may be literally paying in cold-hard cash for everything you send over the wire – or may be experiencing your site over a degraded “4G” connection towards the end of the month.
  • Aggressively cache assets to prevent re-downloading anything you’ve sent before. Don’t make the user pay twice if they don’t have to.
  • Progressively load additional assets and information as the user requests them, rather than a big upfront payload, that way you’re giving the end user a little more choice about whether they want or need that extra data set.

This is all to say that as web developers, we have a lot more control over how and when we deliver the meat of our products - unlike native apps that generally send the whole experience down as one multi-megabyte download that our 4G and data-strapped users can’t afford.

Make a wish

Finally, it’s time for your gift recipients to go out onto the web and find whatever their greatest wish is. For many, that’s going to begin when they first turn on their phone and see all those enticing icons on their home screen. Opening a browser may not be their first port of call.

They’ll be primed to look for sites and information through the icon-heavy menu that most mobile OSs use today, and they will be encouraged to find new experiences through the provided app store interface.

The good news is that web experience can be found in many modern app-stores today.

For example, if you build an app using Trusted Web Activities, the Google Play Store will list your web site right alongside native apps and allow users to install them on their phones. Samsung and Microsoft have similar options without the extra step of creating a TWA - they’ll list any Progressive Web App in their stores. Tools like Microsoft’s PWA Builder and Llama Pack are making this easier than ever.

If your users are primed to search for new experiences via a search engine instead, then they’ll benefit from the work you’ve put in to list them in app stores regardless, as PWAs are first and foremost about making websites mobile-friendly, regardless of point of sale. A PWA will provide them with offline support, service works, notifications and much more.

We do have a grinch in this story, however.

Apple’s iOS explicitly does not allow your website to be listed in their app store, so sadly you’ll have a harder time reaching those users. But it is possible! Fortunately, iOS isn’t as all-dominating world wide as it is in the tech community, selling only around 10-15% of smartphones out in the world.

The best present

The WWW is a wonderful gift that we received over 30 years ago and, as web developers, we get to steward and share this truly global, open, platform with millions of people every day. Let’s take care of it by building and sharing experiences that truly meet the needs of everyone.


About the author

Frances Berriman is a San Francisco-based British-born designer and web developer who blogs at fberriman.com. She’s done all sorts of things, but has a special soft spot for public sector projects, and has worked for the Government Digital Service, building GOV.UK, Code for America, Nature Publishing and the BBC and is currently Head of UX and Product Design at Netlify.

More articles by Frances




if

A History of CSS Through Fifteen Years of 24 ways

Rachel Andrew guides us through a tour of the last fifteen years in CSS layout, as manifested in articles here on 24 ways. From the days when Internet Explorer 6 was de rigueur, right up to the modern age of evergreen browsers, the only thing you can be sure of is that the web never stands still for long.


I’ve written nine articles in the 15 years of 24 ways, and all but one of those articles had something to do with CSS. In this last year of the project, I thought I would take a look back at those CSS articles. It’s been an interesting journey, and by reading through my words from the last 15 years I discovered not only how much the web platform has evolved - but how my own thinking has shifted with it.

2005: CSS layout starting points

Latest web browser versions: Internet Explorer 6 (at this point 4 years old), IE5.1 Mac, Netscape 8, Firefox 1.5, Safari 2

Fifteen years ago, my contributions to 24 ways started with a piece about CSS layout. That article explored something I had been using in my own work. In 2005, most of the work I was doing was building websites from Photoshop files delivered to me by my design agency clients. I’d built up a set of robust, tried-and-tested CSS layouts to use to implement these. My starting point when approaching any project was to take a look at the static comps and figure out which layout I would use:

  • Liquid, multiple column with no footer
  • Liquid, multiple column with footer
  • Fixed width, centred

At that point, there were still many sites being shipped with table-based layouts. We had learned how to use floats to create columns some four years earlier, however layout was still a difficult and often fragile thing. By developing patterns that I knew worked, where I had figured out any strange bugs, I saved myself a lot of time.

Of course, I wasn’t the only person thinking in this way. The two sites from which the early CSS for layout enthusiasts took most of their inspiration, had a library of patterns for CSS layout. The Noodle Incident little boxes is still online, glish.com/css is sadly only available at the Internet Archive.

This thinking was taken to a much greater extreme in 2011, when Twitter Bootstrap launched and starting with an entire framework for layout and much more became commonplace across the industry. While I understand the concern many folk have about every website ending up looking the same, back in 2005 I was a pragmatist. That has not changed. I’ve always built websites and run businesses alongside evangelizing web standards and contributing to the platform. I’m all about getting the job done, paying the bills, balancing that with trying to make things better so we don’t need to make as many compromises in the future. If that means picking from one of a number of patterns, that is often a very reasonable approach. Not everything needs to be a creative outpouring.

Today however, CSS Grid Layout and Flexbox mean that we can take a much more fluid approach to developing layouts. This enables the practical and the creative alike. The need for layout starting points - whether simple like mine, or a full framework like Bootstrap - seems to be decreasing, however in their place comes an interest in component libraries. This approach to development partly enabled by the fact that new layout makes it possible to drop a component into the middle of a layout without blowing the whole thing up.

2006: Faster Development with CSS Constants

Latest web browser versions: Internet Explorer 7, Netscape 8.1, Firefox 2, Safari 2

My article in 2006 was once again taken from the work I was doing as a developer. I’ve always been as much, if not more of a backend developer than a frontend one. In 2006, I was working in PHP on custom CMS implementations. These would also usually include the front-end work. Along with several other people in the industry I’d been experimenting with ways to use CSS “constants” as we all seemed to call them, by processing the CSS with our server-side language of choice.

The use case was mostly for development, although as a CMS developer, I could see the potential of allowing these values to be updated via the CMS. Perhaps to allow a content editor to change a color scheme.

Also in 2006, the first version of Sass was released, created by Hampton Catlin and Natalie Weizenbaum. Sass, LESS and other pre-processors began to give us a more streamlined and elegant way to achieve variables in CSS.

In 2009, the need for pre-processors purely for variables is disappearing. CSS now has Custom Properties - something I did not foresee in 2006. These “CSS Variables” are far more powerful than swapping out a value in a build process. They can be changed dynamically, based on something changing in the environment, rather than being statically set at build time.

2009: Cleaner Code with CSS3 Selectors

Latest web browser versions: Internet Explorer 8, Firefox 3.5, Safari 4, Chrome 3

After a break from writing for 24 ways, in 2009 I wrote this piece about CSS3 Selectors, complete with jQuery fallbacks due to the fact that some of these selectors were not usable in Internet Explorer 8.

Today these useful selectors have wide browser support, we also have a large number of new selectors which are part of the Level 4 specification. The changes section of the Level 4 spec gives an excellent rundown of what has been added over the years. Browser support for these newer selectors is more inconsistent, MDN has an excellent list with the page for each selector detailing current browser support and usage examples.

2012: Giving Content Priority with CSS3 Grid Layout

Latest web browser versions: Internet Explorer 10, Firefox 17, Safari 6, Chrome 23

My 2012 piece was at the beginning of my interest in the CSS Grid Layout specification. Earlier in 2012 I had attended a workshop given by Bert Bos, in which he demonstrated some early stage CSS modules, including the CSS Grid Layout specification. I soon discovered that there would be an implementation of Grid in IE10, the new browser shipped in September of 2012 and I set about learning how to use Grid Layout. This article was based on what I had learned.

The problem of source versus visual order

As a CMS developer I immediately linked the ability to lay out items and prioritize content, to the CMS and content editors. I was keen to find ways to allow content editors to prioritize content across breakpoints, and I felt that Grid Layout might allow us to do that. As it turned out, we are still some way away from that goal. While Grid does allow us to separate visual display from source order, it can come at a cost. Non-visual browsers, and the tab order of the document follow the source and not the visual display. This makes it easy to create a disconnected and difficult to use experience if we essentially jumble up the display of elements, moving them away from how they appear in the document. I still think that an issue we need to solve is how to allow developers to indicate that the visual display should be considered the correct order rather than the document order.

The Grid Specification moved on

Some of the issues in this early version of the grid spec were apparent in my article. I needed to use a pre-processor, to calculate the columns an element would span. This was partly due to the fact that the early grid specifications did not have a concept of the gap property. In addition the initial spec did not include auto-placement and therefore each item had to be explicitly placed onto the grid. The basics of the final specification were there, however over the years that followed the specification was refined and developed. We got gaps, and auto-placement, and the grid-template-areas property was introduced. By the time Grid shipped in Firefox, Chrome, and Safari many of the sticky things I had encountered when writing this article were resolved.

2015: Grid, Flexbox, Box Alignment: Our New System for Layout

Latest web browser versions: Edge 13, Firefox 43, Safari 9, Chrome 47

Grid still hadn’t shipped in more browsers but the specification had moved on. We had support for gaps, with the grid-row-gap, grid-column-gap and grid-gap properties. My own thinking about the specification, and the related specifications had developed. I had started teaching grid not as a standalone module, but alongside Flexbox and Box Alignment. I was trying to demonstrate how these modules worked together to create a layout system for modern web development.

Another place my thinking had moved on since my initial Grid article in 2012, was in terms of content reordering and accessibility. In July of 2015 I wrote an article entitled, Modern CSS Layout, Power and Responsibility in which I outlined these concerns.

Some things change, and some stay the same. The grid- prefixed gap properties were ultimately moved into the Box Alignment specification in order that they could be defined for Flex layout and any other layout method which in future required gaps. What I did not expect, was that four years on I would still be being asked about Grid versus Flexbox:

“A question I keep being asked is whether CSS grid layout and flexbox are competing layout systems, as though it might be possible to back the loser in a CSS layout competition. The reality, however, is that these two methods will sit together as one system for doing layout on the web, each method playing to certain strengths and serving particular layout tasks.”

2016: What next for CSS Grid Layout?

Latest web browser versions: Edge 15, Firefox 50, Safari 10, Chrome 55

In 2016, we still didn’t have Grid in browsers, and I was increasingly looking like I was selling CSS vaporware. However, with the spec at Candidate Recommendation, and it looking likely that we would have grid in at least two browsers in the spring, I wrote an article about what might come next for grid.

The main subject was the subgrid feature, which had by that point been removed from the Level 1 specification. The CSS Working Group were still trying to decide whether a version of subgrid locked to both dimensions would be acceptable. In this version we would have declared display: subgrid on the grid item, after which its rows and columns would be locked to the tracks of the parent. I am very glad that it was ultimately decided to allow for one-dimensional subgrids. This means that you can use the column tracks of the parent, yet have an implicit grid for the rows. This enables patterns such as the one I described in A design pattern solved by subgrid. At the end of 2019, we don’t yet have wide browser support for subgrid, however Firefox has already shipped the value in Firefox 71. Hopefully other browsers will follow suit.

Level 2 of the grid specification ultimately became all about adding support for subgrid, and so we don’t yet have any of the other features I mentioned in that piece. All of those features are detailed in issues in the CSS Working Group Github repo, and aren’t forgotten about. As we come to decide features for Level 3, perhaps some of them will make the cut.

It was worth waiting for subgrid, as the one-dimensional version gives us so much more power, and as I take a look back over these 24 ways articles it really underlines how much of a long game contributing to the platform is. I mentioned in the closing paragraph of my 2016 article that you should not feel ignored if your idea or use case is not immediately discussed and added to a spec, and that is still the case. Those of us involved in specifying CSS, and in implementing CSS in browsers care very much about your feedback. We have to balance that with the need for this stuff to be right.

2017: Christmas Gifts for Your Future Self: Testing the Web Platform

Latest web browser versions: Edge 16, Firefox 57, Safari 11, Chrome 63

In 2017 I stepped away from directly talking about layout, and instead published an article about testing. Not about testing your own code, but about the Web Platform Tests project, and how contributing to the tests which help to ensure interoperability between browsers could benefit the platform - and you.

This article is still relevant today as it was two years ago. I’m often asked by people how they can get involved with CSS, and testing is a great place to start. Specifications need tests in order to progress to become Recommendations, therefore contributing tests can materially help the progress of a spec. You can also help to free up the time of spec editors, to make edits to their specs, by contributing tests they might otherwise need to work on.

The Web Platform Tests project has recently got new and improved documentation. If you have some time to spare and would like to help, take a look and see if you can identify some places that are in need of tests. You will learn a lot about the CSS specs you are testing while doing so, and you can feel that you are making a useful and much-needed contribution to the development of the web platform.

2018: Researching a Property in the CSS Specifications

Latest web browser versions: Edge 17, Firefox 64, Safari 12, Chrome 71

I almost stayed away from layout in my 2018 piece, however I did feature the Grid Layout property grid-auto-rows in this article. If you want to understand how to dig up all the details of a CSS property, then this article is still useful.

One thing that has changed since I began writing for 24 ways, is the amount of great information available to help you learn CSS. Whether you are someone who prefers to read like me, or a person who learns best from video, or by following along with a tutorial, it’s all out there for you. You don’t have to rely on understanding the specifications, though I would encourage everyone to become familiar with doing so, if just to be able to fact check a tutorial which seems to be doing something other than the resulting code.

2019: And that’s a wrap

Latest web browser versions: Edge 18, Firefox 71, Safari 12, Chrome 79

This year is the final countdown for 24 ways. With so many other publications creating great content, perhaps there is less of a need for an avalanche of writing in the closing days of each year. The archive will stay as a history of what was important, what we were thinking, and the problems of the day - many of which we have now solved in ways that the authors could never have imagined at the time. I can see through my articles how my thinking evolved over the years, and I’m as excited about what comes next as I was back in 2005, wondering how to make CSS layout easier.


About the author

Rachel Andrew is a Director of edgeofmyseat.com, a UK web development consultancy and creators of the small content management system, Perch; a W3C Invited Expert to the CSS Working Group; and Editor in Chief of Smashing Magazine. She is the author of a number of books including The New CSS Layout for A Book Apart and a Google Developer Expert for Web Technologies.

She curates a popular email newsletter on CSS Layout, and is passing on her layout knowledge over at her CSS Layout Workshop.

When not writing about business and technology on her blog at rachelandrew.co.uk or speaking at conferences, you will usually find Rachel running up and down one of the giant hills in Bristol, or attempting to land a small aeroplane while training for her Pilot’s license.

More articles by Rachel




if

Imprints for life

An affinity for art and certain turns her life took that drew R. Vaishnavi to tattooing




if

Onam weaves for 2022 comes alive with blooms and Kerala-themed motifs

Designers dress up the traditional cream-and-gold Kerala cotton with hand-painted motifs, embroidery, cut work and more




if

Mahila Praharis of the BSF Camel Contingent will make their Republic Day parade debut in uniform designed by Raghavendra Rathore

The designer also incorporated various skills from across the country and it took him three months to complete the uniform



  • Life &amp; Style

if

Objectifying gender is not ‘jest’




if

Beautiful, naturally

Blossom Kochhar says if you can eat it, it can be used on your face.




if

Give the cauliflower diet a go

Among the endless low-carb, paleo diets for weight loss is the cauliflower diet, which is healthy and doesn’t compromise on taste, says Radha Thomas




if

‘Your life is more than just a number on a weighing scale’

At an event to launch her book Gain to Lose, Dr. Sheela Nambiar said weight training helped women lose weight and cope better with their myriad tasks




if

‘Yoga is life for me’: Tejasvi Kumar Sharma

Tejasvi Kumar Sharma is a standing example of how grit and determination can challenge physical disability




if

Stretch if you can

Moonlight yoga, yoga with sticks, chair yoga… take your pick from this deluge of novel offerings on this World Yoga Day. SHAILAJA TRIPATHI takes a stock




if

Editorial. Gold duty cut can help exporters and consumers if cost savings are passed on 

The customs duty cut on gold, silver and platinum will certainly bring down production costs in this thin-margin industry, helping Indian exports gain competitive edge in the global market




if

Editorial. Lifting the veil

Disclosure from segregated portfolios of FPIs important




if

Editorial. Expanding controls on sugar industry will stifle output

Trying to substitute the operation of market forces in an industry with micro-management of demand, supply and prices creates uncertainty for entrepreneurs




if

Editorial. Liberal norms in GIFT City, the right way forward

Will not only boost the primary market activity in the GIFT IFSC but will also enable GIFT City to effectively compete with other international financial jurisdictions




if

Editorial. Edible oil tariffs must balance farmer, consumer needs

Curbs on edible oil exports must be relaxed so that farmers have the freedom to capitalise on global market opportunities, just as consumers benefit from cheap imports




if

IIFL Finance grows its gold loan portfolio by ₹2,000 cr about a month after RBI lifted lending ban

IIFL Finance’s gold loan book had shrunk from ₹26,000 crore in early March 2024 to ₹10,000 crore by September 19, 2024



  • Money &amp; Banking

if

IFC invests $400 million in Bajaj Finance, aiming to quadruple climate loans by 2027

This investment is part of BFL’s $1 billion fundraising goal and aims to support India’s climate goals while promoting financial inclusion



  • Money &amp; Banking

if

Shriram Life’s individual new business premium soars 57% in H1 FY25

Shriram Life sold 2.83 lakh individual policies, a 96 per cent increase from the previous year



  • Money &amp; Banking

if

Max Life integrates Swiss Re’s digital health underwriting into its operations

Real-time risk assessment using Swiss Re’s digital health solution is expected to enhance efficiency and elevate the customer experience



  • Money &amp; Banking