Automatically translated.View original post

css perspective+tranform

# Web Site Writing Basics

# perspective # Tranform

# CSS

CSS Perspective is a feature used to create a 3D space for elements on a web page, determining the distance of the audience from the object, making the elements that are transformed (such as rotation) appear as real as what our eyes see in real life, such as objects that are closer to looking larger than objects that are far away, and affecting the depth of the overall picture. The smaller the perspective, the larger and closer the object looks to our eyes, the clearer the 3D dimension.

Perspective working principle

Create a 3D space:

The perspective property will enable 3D space for the subelements being transformed.

Define spacing:

The value of the perspective is the distance from the user to the Z-plane where the object is.

Effect on vision:

Minor Value: Make an object appear larger when it is near, and it has a distinctive dimension.

Very valuable: The depth effect will look more delicate, the object will look flattened.

Application to Transform:

Perspective is often combined with other CSS features, such as transform: rotateY (), to create the illusion of rotating 3D objects.

Difference between perspective and transform: perspective ()

Perspective (features):

Use with the parent Element to create a 3D space together for all converted child Element.

Transform: perspective () (function):

Use directly with the Element to be converted to determine the depth of the object directly.

Example of use

Code

/ * Assign 3D space to container * / .container {perspective: 1000px; / * Define user spacing * /}

/ * Convert child element to rotate and dimensional * / .child-element {transform: rotateY (30deg); / * element rotation example * /

}

2025/9/8 Edited to

... Read moreหลังจากที่เข้าใจหลักการพื้นฐานของ CSS perspective และ transform แล้ว สิ่งที่ผมอยากแนะนำเพิ่มเติมคือการใช้ค่า perspective ที่เหมาะสมกับขนาดและลักษณะของหน้าเว็บเพื่อให้ได้เอฟเฟกต์มิติโดยไม่ทำให้วัตถุดูหลอกตาเกินไป จากประสบการณ์จริง การตั้ง perspective ที่ค่าประมาณ 800px-1000px มักจะให้ความรู้สึกสมจริงและนุ่มนวลกำลังดี โดยค่าที่น้อยเกินไปวัตถุจะดูใหญ่มากและใกล้ชิดจนเกินไป ส่วนค่ามากเกินไปจะทำให้องค์ประกอบดูแบนราบและมิติหายไป นอกจากนี้ การประยุกต์ใช้ perspective ควรกำหนดไว้ที่ container หลัก เพราะจะช่วยควบคุมพื้นที่สามมิติของลูกหลานทั้งหมดที่ถูกแปลงข้างในได้อย่างมีประสิทธิภาพ ขณะที่ transform: perspective() จะใช้ในกรณีที่ต้องการกำหนดความลึกเฉพาะเจาะจงให้กับองค์ประกอบใดองค์ประกอบหนึ่งเท่านั้น สำหรับการใช้งานร่วมกับ rotateY() หรือฟังก์ชัน transform แบบอื่นๆ ผมแนะนำให้ลองเพิ่ม transition เพื่อให้การเปลี่ยนแปลงท่าทางของวัตถุดูราบรื่นและน่าสนใจยิ่งขึ้น เช่น การเขียนโค้ด transition: transform 0.5s ease; ซึ่งจะช่วยส่งเสริมประสบการณ์ผู้ใช้และทำให้เว็บไซต์ดูทันสมัยมากขึ้น ทั้งนี้สามารถนำเทคนิค perspective + transform มาประยุกต์ใช้กับส่วนประกอบต่างๆ เช่น การสร้างปุ่มที่มีมิติ หรือกล่องแสดงเนื้อหาที่หมุนได้ เพื่อเพิ่มความน่าสนใจและทันสมัยให้เว็บไซต์ของคุณอย่างแท้จริง

Related posts

Choose the best perspective of yourself ❤️
#selflove #girladvice #confidence #confidencetips #confidentvibes
Kailey Anna

Kailey Anna

6921 likes

That changed my perspective
#itgurl #selflove #selfimprovement #selfcare
J.Rubyy

J.Rubyy

1902 likes

A split image displays satellite views comparing Hurricane Katrina (Cat 3, 125 max winds, 400 miles diameter, 230 miles wind field) and Hurricane Helene (Cat 4, 140 max winds, 822 miles diameter, 370 miles wind field).
To better put it in perspective
#pray
💜 Samantha  )•¥|\|€R 💜

💜 Samantha )•¥|\|€R 💜

220 likes

A young woman in a sparkly silver top and black skirt takes a mirror selfie in a bathroom, smiling. Text overlay reads, "Today was the absolute best day ever."
A city skyline is visible through a window at sunrise, with orange and blue skies. The foreground shows a bed or couch. Text overlay says, "I got to see the sunrise..."
A young woman takes a selfie with an older woman, both smiling, standing next to a canal or river outdoors. Text overlay reads, "I got to give my mom a hug."
Perspective
#mindset #positivevibes #motivation
Faith Enokian

Faith Enokian

1057 likes

A hand holds a book against a textured grey-green blanket, with the overlay text "this book CHANGED MY LIFE" in white boxes.
The worn black cover of the book "Go Ask Alice" by Anonymous, showing text about millions of copies sold and a companion diary, resting on a grey-green blanket.
An open book displays the first page of "Go Ask Alice," which states it's based on a fifteen-year-old drug user's diary, with an overlay "this is the first page!".
this book shifted my perspective 📚⭐️
📚 Title and Author: Go Ask Alice by Anonymous 🌟 Genre: Memoir 💬 Short Summary: She is a 15-year old girl and is served a drink laced with LSD and that begins her downward spiral with drugs. This is her diary and shows the genuine fear and thought process that she goes through while discoverin
ayersellie

ayersellie

1461 likes

HER perspective of Let Me Down Slowly 💔
#letmedownslowly #alecbenjamin #fyp
Lindsey Jade

Lindsey Jade

2191 likes

A book page from 'The Mountain Is You' with highlighted text discussing how rock bottom can be a turning point, leading to a declaration of change and a journey of self-awareness and growth.
A book page from 'The Mountain Is You' with highlighted text encouraging self-directed rage and determination to change one's life and not continue as one is, under the heading 'PREPARING FOR RADICAL CHANGE'.
The black cover of the book 'The Mountain Is You' by Brianna Wiest, featuring a gold mountain graphic and the subtitle 'TRANSFORMING SELF-SABOTAGE INTO SELF-MASTERY'.
This book changed my perspective on everything
Hey there, book lovers! 📚✨ Just dove into "The Mountain Is You" by Brianna Wiest, and it's a total game-changer! 🏔️💡 It's all about turning self-sabotage into self-mastery. If you're ready to conquer your inner mountains and unlock your potential, this one's a must-read. 🌟🧠
Jenna Weems

Jenna Weems

474 likes

A motivational image titled 'Perspective is Everything' highlighted in yellow. It lists negative experiences like 'Discomfort,' 'Problems,' and 'Pain,' with arrows pointing to positive reframings such as 'Growth,' 'Challenges,' and 'Power.' The image promotes changing one's outlook on life's difficulties.
Perspective????
Whenever we have problems we always think of the worst however, what if we change the way we think. What if instead we change our negative thoughts with positivity. Just by doing that we can change our whole attitude and outlook on life. Which gives us a new perspective. If you change t
Lakesha

Lakesha

650 likes

Tone the back —> force perspective
These exercises will shrink the lower back and (slightly) widen the upper back, encouraging an hourglass shape. Exercise #1 - Lateral pull downs These will sculpt the sides of your back, growing the lats into a funnel (more or less) shape. Exercise #2 - Gorilla rows This will whit
Ashara Wilson

Ashara Wilson

45 likes

Cat’s perspective 🥰
#dayinmylife
Elite MaineCoon Breeders

Elite MaineCoon Breeders

4428 likes

A person's midsection with hands forming a heart over a scar near the navel, wearing a brown bra. Overlay text reads, "DON'T RISK YOUR Life FOR A TAN," emphasizing sun protection awareness.
Melanoma changed my whole perspective
After being diagnosed with melanoma and having several scars on my body, I have become so diligent about sun protection and getting my glow in a safer, healthier way. I absolutely love having tan skin, but it’s definitely not worth risking my life over. I’ve tried countless tanning mousses and this
Briprov

Briprov

2018 likes

🫶Gratitude journal prompts to shift perspective
Shifting perspective through gratitude doesn't mean ignoring problems but rather training your mind to also see the good that coexists with challenges. These prompts help you develop a gratitude practice that goes deeper than surface-level thankfulness, revealing hidden blessings and reframing
FawnAndFern

FawnAndFern

53 likes

A handwritten list in a notebook titled 'Shift Your Perspective,' showing negative thoughts reframed with gratitude and faith, ending with a summary from 1 Thessalonians 5:18.
✨Shift your perspective✨
It’s time for us to shift our perspective towards our situations. God got us, draw near him and he’ll draw near to you! James 4:8 ✨Scriptures✨ 💕“Draw near to God and He will draw near to you. Cleanse your hands, you sinners; and purify your hearts, you double-minded.” ‭‭James‬ ‭4‬:‭8‬ ‭NKJV‬
Mykala Charles

Mykala Charles

402 likes

An interesting perspective on Black Africans
#selfhelpbooks #lemon8challenge My Current Read 📖 Name of the Book: Black Tax 📄 Plot: N/A 📖 Genre: Self Help 📄 My Favorite Quotes: "Though I drive in the valley of the shadow of death I fear no hijackers, but another fuel increase." 😂 💭 My Thoughts: hmm🤔? ⭐ Star Rating: 4.2
Anesu

Anesu

156 likes

A natural landscape with a stream flowing through trees, featuring overlaid text "Perspective Art SWIPE" with decorative butterflies and arrows, serving as a cover image.
An illustration of a person sitting on the floor in a bedroom with a distorted perspective. The room is filled with posters, a keyboard, and a bed, creating a unique artistic view.
An illustration of a person sitting on a bed with a colorful quilt in a room. The walls are covered with numerous band posters and artwork, showcasing a unique perspective.
beautiful art form 🌿
enjoy perspective art 🎀 ____________________________________ #beautifulartstyle #art #embracevulnerability #perspective #roomtour #motivation #drawings #gaming #aesthetic #Lemon8Diary
•●◉✿Lynn✿◉●•

•●◉✿Lynn✿◉●•

59 likes

4 books to shift your perspective for 2025
2025 is our year and so is every year to come 💕 📍 Boston #thepsychologyofmoney #luckygirlsyndrome #booktok
kendra

kendra

373 likes

It’s all about perspective ✨
This collage explores how perspective shapes experience. How the same world can feel different depending on where we place our attention. It reflects a grounded kind of optimism, choosing to notice what’s still good without denying what isn’t. #collageart #embracevulnerability #arttherapy
Sarah Montour

Sarah Montour

15 likes

Flower Shops from the girl’s perspective 💕
#flowershops #countrymusic #rewrite #girlsperspective #ernest
Emmy Moyen

Emmy Moyen

158 likes

Purple teeth for perspective
From drinking a minimum of bottle of wine a night while also binging throughout the week and weekends my face had become so swollen. Within a month the swelling had gone down! #sober #sobriety #wedorecover #smile #fypシ
Katie Garner

Katie Garner

534 likes

Perspective 🤍
#mindset #quotes #kindness #girlhood
Faith Enokian

Faith Enokian

158 likes

Perspective really is everything 💭
Instead of saying “ugh I have to wake up early for my workout,” I remind myself — I get to wake up, move my body, and have access to a gym… and why not have fun with it too? 🏋️‍♀️✨ Gratitude changes the whole vibe 🤍 #MindsetShift #WellnessJourney #GratitudeAttitude #HealthyMindset #
Sarina Agarwal

Sarina Agarwal

31 likes

A planner page displays 10 handwritten relationship lessons, including 'Love should feel safe, Not stressful' and 'Actions speak Louder than Words'. A drawing of a flower with green leaves is at the bottom, with 'Lemon8' and '@speckled_red' watermarks.
Relationship Lessons That Changed My Perspective
These relationship lessons have completely shifted how I see love, boundaries, and self-worth
Speckled_Red

Speckled_Red

146 likes

Lies Lies Lies from the girl’s perspective
This song is sooo good!! #morganwallen #lieslieslies #countrymusic
Emmy Moyen

Emmy Moyen

2989 likes

Hair Perspective 🪮
#lemon8diarychallenge fr tho I use to be a productholic… I blame the natural hair YouTubers😭 #afro #afrohair #naturalhairstruggles #naturalhairchronicles
Afrodite

Afrodite

136 likes

Some fresh perspective to help you heal & grow
Healing doesn’t always look like a breakthrough. Sometimes it looks like pausing, choosing differently, or simply getting through the day. If you see yourself in any of these…you’re doing better than you think. Save this as a reminder. ❤️ #healingjourney #innergrowth #emotionalhea
therosypeony

therosypeony

20 likes

Books That Will Change Your Perspective: Part 1
“Show Up As Her - Ten Laws for Reclaiming Your Power, Embodying Magnetic Energy, and Positive Manifestation (Self-Love, Manifestation Book)”💞 This book extensively covers the topic of self confidence, Self Love, & Self Realization. It’s referred to as a self love book that “the big sister
Your Digital Bestie🌷

Your Digital Bestie🌷

77 likes

A stadium at sunset with a vibrant orange and purple sky, filled with spectators in the stands. Bright stadium lights illuminate the scene. The text overlay reads: "ATHLETE QUOTES YOU NEED TO HERE."
A track and field stadium at sunset, featuring a running track and a green field under a colorful sky. The text overlay states: "its going to hurt regardless, so it might as well hurt in first place."
A soccer goal on a misty green field, with the net prominent in the foreground. The text overlay reads: "If I quit now, I'll soon be back to where I started. And when I started, I was desperately wishing to be where I am now."
athlete quotes that will change your perspective🥰
audrey

audrey

45 likes

A smiling young woman with blonde hair stands outdoors, wearing a light blue sweater and dark vest. The image has text overlay "A verse that has changed my perspective" and a "Swipe" indicator, suggesting more content.
A verse that has changed my perspective
Hebrews 4:15🤌🏼 I knew that Jesus walked this earth as a human but I never fully grasped that while He is divine, holy, and perfect, He was tempted. He felt the feelings I feel. He experienced normal, worldly things like we encounter every day. Jesus knows the hardships I am facing and the battle
Kacey🌿

Kacey🌿

248 likes

Mindful perspective 🫶
Imagine living life for 80 years - and waking up one day back in your 28-year-old life and body. How would you spend your days? How would you speak to yourself? Who would you spend time with? A reminder that life is beautiful. Practice gratitude everyday. 🤍 #perspective #moments #li
Sav, MSc, BSc

Sav, MSc, BSc

702 likes

An open book rests on a blue towel on a sandy beach at sunset. Text overlay reads "Quotes that changed my perspective Life recently" with decorative elements and a "REC" icon.
A white background displays the quote: "It's about who stands in the rain with you, when they also have a choice to be dry. Remember that."
A white background displays the quote by Hazel Satija: "pay close attention to how your body feels around certain people your body will quite literally reject what is not for you."
Quotes that changed my perspective
these are some quotes that I’ve been thinking about non-stop. I’ve always come back to these quotes. It really shifted my perspective on life and my faith. #inspirational quotes 💌 #inspirational #quote to live by #lifequotes #embracevulnerability
Linamalk233

Linamalk233

346 likes

Perspective
How about we shift your perspective to something beneficial
Autumn Ivy

Autumn Ivy

71 likes

Sometimes all we need is perspective
I am guilty of the talk. Talking to my friends, especially when it comes to the one person who attempts to hurt my family. She deserves forgiveness, just as much as anyone else. I am guilty of getting mad and staying mad. I am guilty of a grudge. I am guilty of doing wrong. I need to forgive myself
Taylor

Taylor

240 likes

One book that’s changed your perspective on life?
Okay I’m going to be honest here….. All of the things Mel talks about in her book are all things I have been doing and implementing wayyyyyy before she wrote about it. In fact, some of these things are legit words out of my mouth way before she came out with this book. But I guess because she’s
Bexx

Bexx

240 likes

What if Call Out My Name was from her perspective?
[villain mode: activated] 😈 #theweeknd #calloutmyname #narcissist #lyrics #singing #rnb #mydearmelancholy
Lindsey Jade

Lindsey Jade

106 likes

Perspective ✨🤍🙏🏽
#Focus #Good #dailyroutine #perspective #Lemon8Diary
OneRareTina🤍🌻💛

OneRareTina🤍🌻💛

17 likes

Change Your Perspective ✨🫶
If you can change your perspective you can change your mood! #motivation #inspiration
Daily Peptalks Tv

Daily Peptalks Tv

21 likes

all about perspective 🎀✨🌷💓💐
this is my main goal for 2024 !! #gymoutfit #gymlifestyle #Fitness #fitnessmotivation #lifestyle #healthylifestyle2024 #mentalhealth
lauren whitton

lauren whitton

635 likes

A positive perspective on medical school
#medicalschool #medicalstudent #doctor #premed #premedstudent
Sonia | Doctorinthemaking

Sonia | Doctorinthemaking

27 likes

A beach scene with a blue towel on sand, featuring a pink leopard print bag, a phone, sunglasses, a snack, a water bottle, and a bottle of sun protection lotion. The text "IMAGES THAT WILL CHANGE YOUR PERSPECTIVE" is overlaid.
A blue background displays a timeline of months with an arrow pointing to "may" and the phrase "you are here". Below are labels for "experience" and "opportunity" next to colored circles.
On a light background, two blue circles illustrate "mind full" with tangled lines and "mindful" as an empty outline, contrasting mental states.
Images that Changed my Perspective on Life
#imagery #quotesoftheday #inspiration #unfiltered #Lemon8Diary
OLIVIA 🧸😇🐚👸🏽🌷

OLIVIA 🧸😇🐚👸🏽🌷

452 likes

🌸A Fresh Set & A Fresh Perspective 💕
POV: You finally stop waiting for life to get easier and start making it beautiful anyway. 🌸💅🏾 Fresh nails, a little sunshine, and a reminder that soft living isn’t about having a perfect life—it’s about finding moments of joy in the one you’re living. 💕✨ Sometimes healing looks like therapy.
Lessie Lynette

Lessie Lynette

23 likes

Perspective 🌸
Sometimes we get so caught up in the details that we forget to step back and see the bigger picture. Trust the process, embrace the journey, and remember that every piece fits perfectly in time. #Perspective #BiggerPicture #MindsetMatters #GrowthJourney #TrustTheProcess #Inspiratio
Annie | 📚👗💄🪷

Annie | 📚👗💄🪷

6 likes

A person in a cow-print hoodie holds 'The Untethered Soul' book, with text overlay stating it's a book that changed their perspective on everything.
Four images show open spiral notebooks filled with handwritten notes, alongside copies of 'The Untethered Soul' book, indicating deep engagement and note-taking.
A white background displays a numbered list of 20 key concepts and takeaways from 'The Untethered Soul' book, covering topics like self, mind, consciousness, and liberation.
this book changed my perspective on EVERYTHING🤯📖
Hands down my favorite self-help/spiritual book I’ve ever read🥹🤍 This book reframed the way I think & made me finally understand what “you are not your thoughts” ACTUALLY means. l resonated so deeply with every word and felt so much lighter after reading it. I also loveee the analogies he us
Halle Buttafuso

Halle Buttafuso

442 likes

See more