FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

CSS background-image on Label not loading in iOS · Issue #2414 · NativeScript/NativeScript · GitHub

CSS background-image on Label not loading in iOS #2414

Description

Logged from @tim (admin ticket)

I can't seem to get a background image to appear on a label at all. I am developing using Platform in-browser client and livesyncing to Android and iOS devices. I'd really appreciate your help here. We're close to deploying our app. I want to be able to get this working.

Issue - can't load image via CSS background-image on Label
page.css

.imageBackground {
  background-image: url('~/images/icon.png');
  background-repeat: no-repeat;
  background-position: left;
  background-size: contain;
}

page.xml

<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="navigatingTo">
  <StackLayout>
    <Label text="label" class="imageBackground" textWrap="true"/>  <!-- NOT Working -->
    <Button text="button" class="imageBackground" textWrap="true"/> <!-- Works (suggested workaround) -->
  </StackLayout>
</Page>

Code to reproduce this issue: https://github.com/NickIliev/ticket-1047813

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL