GithubHelp home page GithubHelp logo

No linebreaks in subtitle? about alerttoast HOT 9 CLOSED

elai950 avatar elai950 commented on May 18, 2024 5
No linebreaks in subtitle?

from alerttoast.

Comments (9)

elai950 avatar elai950 commented on May 18, 2024 2

This bug was fixed in 1.3.9.
Please check.

from alerttoast.

aledebla03 avatar aledebla03 commented on May 18, 2024 1

Same here, also in title

from alerttoast.

AnmolMalpani avatar AnmolMalpani commented on May 18, 2024 1

Title going out of the screen
Screenshot 2022-03-10 at 5 22 59 PM
.

from alerttoast.

RudraSen2 avatar RudraSen2 commented on May 18, 2024

Try Adding <br> to the text if you're using SwiftUI 3.

from alerttoast.

elai950 avatar elai950 commented on May 18, 2024

Hey @GrosserStuhl ,
I tried to reproduce the issue on my side with no luck.

As you can see in the picture this very long string does linebreak where it needs to.
I'll close this issue for that reason but please keep me updated if you find the cause of this problem. I'm curious.

.toast(isPresenting: $showBannerRegular, duration: 4){
                    AlertToast(displayMode: .banner(.slide), type: .regular, title: "Welcome! 👋", subTitle: "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.", style: .style(backgroundColor: .blue))
                }

צילום מסך 2023-01-31 ב-10 21 43

from alerttoast.

harleylovitos avatar harleylovitos commented on May 18, 2024

I'm having this issue here. It was working last 2nd or 1st week of January but now it showing like this.
IMG_1886

from alerttoast.

elai950 avatar elai950 commented on May 18, 2024

I'm having this issue here. It was working last 2nd or 1st week of January but now it showing like this.

IMG_1886

From previous tests, it might be because you didn't specified width to the view that the toast modifier is on him.
Try give him a frame width of even infinity in a vstack and see if it solved.

Usually this problem occurring when there is so width to the view.
Generally speaking in SwiftUI I mean.

from alerttoast.

harleylovitos avatar harleylovitos commented on May 18, 2024

I added this code and same problem.
ZStack {VStack{ some code.... }.padding(20) .frame(maxWidth: .infinity) .toast(isPresenting: self.$showToast,duration: 5, tapToDismiss: true, alert: { AlertToast(displayMode: .banner(.slide),type: self.toastType, title: self.toastMessage) }, onTap: { some codes... }, completion: { some codes... }) }

I also tried .frame(width: .infinity)

IMG_1889

from alerttoast.

harleylovitos avatar harleylovitos commented on May 18, 2024

Thank you :)

from alerttoast.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.